This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* HTML PRIDE! */ | |
html { | |
-webkit-animation: rainbow 8s infinite; | |
} | |
/* | |
Spin all images | |
*/ | |
img { | |
-webkit-animation: spin 1s linear infinite; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> import requests | |
>>> r = requests.get('http://www.luoo.net/radio/radio2/mp3player.xml') | |
>>> r.status_code | |
200 | |
>>> print r.content | |
锘??xml version="1.0" encoding="UTF-8"?> | |
<player showDisplay="yes" showPlaylist="yes" autoStart="yes"> | |
<song path="http://ftp.luoo.net/radio/radio2/1.mp3" title="鏃呰€? /> | |
<song path="http://ftp.luoo.net/radio/radio2/2.mp3" title="绱㈤潪浜? /> | |
<song path="http://ftp.luoo.net/radio/radio2/3.mp3" title="涓夊嘲" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- complete-dict - Created by Ryan Kulla using Python 2.6 on Ubuntu Linux 9.04 on July 23rd 2009 --- | |
--- Python Keywords (These were manually inputted) --- | |
and | |
del | |
for | |
is | |
raise | |
assert | |
elif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
重定向: | |
zsh➜ $ ./file.o | |
before redirect... | |
zsh➜ $ cat demo | |
after redirect... | |
Redirected |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
下载Wget的源代码,下载地址:http://ftp.gnu.org/gnu/wget/ | |
直接安装的话,会发生下面的错误。 | |
checking for compress in -lz... yes | |
checking for gpg_err_init in -lgpg-error... no | |
checking for gcry_control in -lgcrypt... no | |
checking for libgnutls... no | |
configure: error: --with-ssl was given, but GNUTLS is not available. | |
解决: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import requests | |
import sys | |
CITY_RECORD = { | |
# 直辖市 | |
"北京": "101010100", "上海": "101020100", | |
"天津": "101030100", "重庆": "101040100", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
# -*- coding: utf-8 -*- | |
from bs4 import BeautifulSoup | |
import requests | |
import eyed3 | |
import re | |
import urllib | |
import os |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import requests | |
from bs4 import BeautifulSoup | |
import re | |
keywords_pattern = re.compile(r".*/([^.]+).mp4*") | |
subtitles_url_pattern = re.compile(r'<option value="en">English</option>') | |
base_url = "http://www.ted.com" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import subprocess | |
import re | |
ntfs_pattern = re.compile(r'File System Personality: NTFS') | |
ntfs_device_node = re.compile(r'.*Device Node:.*') | |
device_dict = {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import requests | |
import time | |
from bs4 import BeautifulSoup | |
signin_url = "http://www.v2ex.com/signin" | |
award_url = "http://www.v2ex.com/mission/daily" | |
main_url = "http://www.v2ex.com" |
OlderNewer