2009年7月17日 星期五

twow 釣魚小程式

簡易釣魚助手

功能:自動拋竿、收魚竿

請自行下載,並用autoit編譯它

謎之聲:其實是為了測試github才丟出來的XD
code

2009年4月18日 星期六

自動建立XCode專用的git ignore file

寫了一個簡單的建立git程式

工作流程如下:
  1. 呼叫Git init程式,建立基本git資料庫
  2. 產生.gitignore
  3. 產生.gitattributes
  4. 把兩個檔案加入git資料庫
  5. 加上初始註解
#!/bin/bash
## call git init
git init
## make .gitignore
cat > .gitignore << EOF
# Mac OS X Finder and whatnot
.DS_Store
# no useful files
log/*.log
tmp/**/*
public/cache/**/*
doc/api
doc/app
# xcode noise
build/
*.[oa]
*.pbxuser
*.perspective
*.perspectivev3
*.mode1
*.mode1v3
*.mode2v3
# Other source repository archive directories (protects when importing)
.hg
.svn
CVS
# automatic backup files
*~.nib
*.swp
*~
*(Autosaved).rtfd/
Backup[ ]of[ ]*.pages/
Backup[ ]of[ ]*.key/
Backup[ ]of[ ]*.numbers/
# Sparkle distribution Private Key (Don't check me in!)
dsa_priv.pem
EOF
## make .gitattributes
cat > .gitattributes << EOF
*.pbxproj -crlf -diff -merge
EOF
## add .gitignore and gitattributes to git list
git add .gitignore
git add .gitattributes
## add git commit
git commit -m "Git Init for Xcode!"