Twitter の最新の200件の home_timeline をテキストとして読む
Equifax_Secure_Global_eBusiness_CA-1.cer は Equifax Secure Global eBusiness CA-1 (Base-64 encoded X.509) をダウンロードしたもの.
sed のホールドスペースって初めて使ったけど、使いこなせれば色々と面白いことが出来そう. ひたすら入れ替えることになる気はするけどw
2010-01-10 コード修正: 実体参照の処理を追加
2010-01-19 コード修正: 実体参照の処理を修正
wget https://twitter.com/statuses/home_timeline.atom?count=200 \ --ca-certificate Equifax_Secure_Global_eBusiness_CA-1.cer \ --http-user hoge \ --http-password uso800 \ --auth-no-challenge \ --output-document - \ --output-file /dev/null \ | egrep '^ <title>| <updated>' \ | sed -n 's/^ <title>// s|</title>$|| s/^\([^:]*\):/(\1)/ s/&/\&/ s/</</ s/>/>/ s/&/\&/ h n s/^ <updated>// s|</updated>$| | s/[0-9\-]*T// s/:..+00:00// G s/\n// p' \ | perl -pe 'use HTML::Entities; binmode STDOUT, ":utf8"; decode_entities($_); s/^(\d\d)/sprintf("%02d", ($1 + 9) % 24)/e' \ > home_timeline.txt cygstart home_timeline.txt