RSSArchive About LinkedIn flickr Links to previous projects

[bizkit|張至] good coders code, great steal.

*
Tag
30
Oct
#git   #mac   #geek   #devel  

用 NerdTool 在桌面即時顯示 git commit tree

P1030408

這幾天和 ftt 跟 傑洛 聚在一起 hackthon ,

想了一個方法用大螢幕即時顯示 git 的 commit tree,看起來很有趣,

在 merge 不同 branch 的時候也十分實用。

我們用的程式是 NerdTool,它跟 GeekTool 類似,

是一個可以把任一 command 的 output 顯示在桌面上。

我最早是在 LifeHacker 發現的,

最大的差別在 NerdTool 可以正確的顯示 ASCII colors。

P1030409

我們先從 bitbucket 上另外 clone 了一份 repo 下來專門用來 watch commit 的變動,

接著讓 NerdTool 三秒跑一次 git pull 並用樹狀圖顯示 log 在桌面上:

cd ~/.gitwatch/<repo_name> ; git pull 2>&1 > /dev/null ; date; git lp | head -47

Screen Shot 2011-10-30 at 2.11.47 AM

git 設定的 alias

lp = log —pretty=oneline —abbrev-commit —decorate —graph —color

Screen Shot 2011-10-29 at 4.57.38 PM

後來翻了翻 git log 的 manpage 又把 alias 改了一下,顯示成自己喜歡的格式,加入了 commiter 、 commit time 兩個資訊,改成照時間排序,又條了一下配色。

lp = log —abbrev-commit —decorate —graph —color —pretty=”format:%Cblue%h\ %Cred%an:%Creset\"%Cgreen%s%Cblue\"\ %Creset%ar” —date-order

gggg

Comments
1
Dec
#mac   #geek  

Mac視窗screenshot關閉陰影

osxchat:

這才找到 如何讓 Cmd-shift-3 在抓視窗時不抓陰影:

defaults write com.apple.screencapture disable-shadow -bool true
killall SystemUIServer
Comments
Page 1 of 1