preload
Mar 20

wget 臬 *nix 銝敺憟賜函撌亙瑯雿唾銝蝬脩頧HTML嚗雿唾銝頛銝桅銝 rpmdebiso tgz 瑼鈭雿芣舀瑼獢摮銝靘嚗wget 質賢啜
鋆⊥鈭銝舐雿輻函靘嚗

wget -r -np -nd http://example.com/packages/

璇賭誘臭誑銝頛 http://example.com 蝬脩銝 packages 桅銝剔隞嗚嗡葉嚗-np 雿冽臭甇瑞嗥桅嚗-nd 銵函內銝冽祆啣萄遣桅蝯瑽

wget -r -np -nd --accept=iso http://example.com/centos-5/i386/

銝銝璇賭誘訾撮嚗雿憭鈭銝 –accept=iso 賊嚗蝷 wget 銝頛 i386 桅銝剜游 iso 隞嗚雿銋臭誑摰憭游嚗芷券喳胯

wget -i filename.txt

甇文賭誘撣貊冽潭寥銝頛敶g閬銝頛隞嗥啣曉 filename.txt 銝哨嗅 wget 撠望芸箔銝頛隞嗡

wget -c http://example.com/really-big-file.iso

鋆⊥摰 -c 賊雿函箸琿蝥喋

wget -m -k (-H) http://www.example.com/

閰脣賭誘舐其∪銝蝬脩嚗wget 撠撠仿脰頧憒蝬脩銝剔舀曉典血蝡暺嚗暻澆臭誑雿輻 -H

蝯嚗wget: some quick tips | Tip o the Day
頧頛靘皞嚗wget 雿輻冽撌

Tagged with:
Mar 08

拍車寞嚗1. Cydia芸摰鋆 2.銝dpkg隞文鋆

寞1嚗

*.deb 曉

/var/root/Media/Cydia/AutoInstall

嗅 iPhone 圈璈喳胯

寞2嚗
*.deb 其噶曉唳對瘥憒隤芣曉

/var/mobile/Media/

cd /var/mobile/Media/

閮敺敺 root 甈

嗅 dpkg -i 隞文鋆 deb

dpkg -i sample.deb

銝璅圈璈喳胯

ps. 憒閬蝘駁斤閰

dpkg -r sample

(芷文隞嗡銝芷方身摰瑼)

Tagged with:
Jan 20

單 iPhone App 隤蝟餃典啣嚗 Localizable.strings 箇楊蝣潮 binary 瑼嚗瘝颲行湔亦冽摮蝺刻摩其耨嫘

曉唳寞 Apple binary property list 頧 XML

plutil -convert xml1 path/to/preferences.plist

link: Convert a Binary Property List to XML – david winter

Tagged with:
Nov 12

Action

apt-get command

aptitude command

Install foo

apt-get install foo

aptitude install foo

Search foo

apt-cache search foo

aptitude search foo

Remove foo

apt-get remove foo

aptitude remove foo

List reverse dependencies

apt-cache rdepends foo

aptitude ~D foo

Print information on priorities for foo

apt-cache policy foo

?

Download foo’s sources and build a binary .deb package

apt-get source –compile foo

?

How to upgrade your distribution
Find out current version of Debian that you are running:

cat /etc/debian_version

Example for upgrading sarge to etch or etch 4.0r1 to 4.0r2 …etc

aptitude update
aptitude dist-upgrade

靘皞嚗Aptitude – Debian Wiki

Tagged with:
Nov 12

箇 Leopard 批遣 Python 其璅∪銝銝剜憿
隞乩 MacPorts 鋆 Python 2.6嚗鋆憟賭敺箇
To fully complete your installation and make python 2.6 the default, please run

sudo port install python_select
sudo python_select python26

python_select嚗Switch the default python interpreter


隞斤扳瘝=.=

航芸楛雿蝯瘥頛靽

cd /usr/bin/
sudo ln -s /opt/local/bin/python python
Tagged with:
Nov 03

-h”Human-readable” output. Use unit suffixes: Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte.
-sDisplay an entry for each specified file. (Equivalent to -d 0)
-ddepth
Display an entry for all files and directories depth directories deep.


芸箇桅憭批嚗

du -sh ~/Documents/EyeTV\ Archive/

3.2G /Users/name/Documents/EyeTV Archive/


箇桅鋆∟府撅斗瑼獢憭批嚗

du -sh ~/Documents/EyeTV\ Archive/*

4.0K /Users/name/Documents/EyeTV Archive/EyeTV Archive.xml
4.0K /Users/name/Documents/EyeTV Archive/EyeTVAutoTune.log
3.2G /Users/name/Documents/EyeTV Archive/勗葆擳 – 桀桀.eyetv
25M /Users/name/Documents/EyeTV Archive/隡蝝W拙 – 蝚17嗆脣怠⊿摮撅梯惇.eyetv

Tagged with:
Oct 21

箏極雿閬銝 PDF 隢頧嚗Mac OS X 10.5 Leopard 批遣璈其犖 Automator 璅撌乩瘚蝔臭誑憟剁雿隞憭拇蹂銝 18 隢靘頧曹憟賢嗾

憒 ImageMagick 芾 10 撟曄嚗

lauct$ time convert example.pdf example.jpg
 
real	0m13.767s
user	0m9.945s
sys	0m0.821s

OSX 瘝批遣 ImageMagick嚗臭誑 MacPorts 摰鋆嚗閮敺閬鋆Ghostscript嚗銝憪撠望臬閮 GS 銝韏瑞楊脖瘝颲行頧

lauct $ sudo port
MacPorts > install  ImageMagick +gs
MacPorts > exit

亥死敺閮剖潸箔銝憭蝎曄溶閰梧啣臭誑銝鈭詻

lauct$ convert -verbose -colorspace RGB -resize 1024 -interlace none -density 300 -quality 95 example.pdf example.jpg

頧箔嚗
霈敹甇行剔蝝璅憭U閰祉摮詻
霈敹甇行剔蝝璅憭U閰祉摮詻

Tagged with: