2014/06/12

DirDiff: 透過 vim 來比對目錄的差異

(吳留手.Taiwan)

好久沒有幫朋友慶生了。
不過這樣說好像我朋友很少的樣子… XD

****
最近由於工作上的需要, 得在Mac上找個能夠比較目錄差異的工具。Mac內建的 filemerge雖然可以比對目錄,但呈現的方式又不盡如人意。找來找去,不是要花錢就是不大好用。後來退而求其次,看看是不是有好用的vim plugin可以幫忙解決這個問題。果然一找就找到了,而且用起來還蠻簡易的。

DirDiff,只要在安裝好之後,先進到vim,然後打下面的指令就可以了。
:DirDiff dir_a dir_b

它會在畫面下方列出目錄兩邊各自才有的檔案,再來是兩邊都有卻有差異的檔案列表。用上下鍵移到每個檔案,再按下Enter就可以在上面呈現 diff。

DirDiff.vim:
http://www.vim.org/scripts/script.php?script_id=102

2014/05/25

Sqlite Commands in Terminal

(Shimen.Taiwan)

Recently, I need to use sqlite commands to check data for my android app. Thanks to the rooted android ROM, the shell environment is much useful than before. It's possible to use Tab key to auto complete filenames and directories, and I can use sqlite3 command directly in adb shell. It saved time from pulling the database file out back and forth.

However, it's been quite a while that I almost forgot how to deal with a sqlite database. The following link is a handy Url to help me on this:

http://www.sqlite.org/cli.html

To name a few:
.mode  // select different modes, eg, list, line, column
select * from tbl1; // select all from table tbl1
 



2014/05/10

光華-蘋果3C電池專家 換 Macbook Pro 2011 電池的經驗

(Taidong.Taiwan)

終於受不了 MacBook Pro 沒有電池的情況下的龜速運轉,帶著電腦直奔光華商場。
沒想到,就是這個沒想到,
老闆之花了15分鐘不到就幫我把電池換好了。
而且在換電池的過程中,不斷地在跟我說電池要怎麼保養,
平常電腦要怎麼使用會比較好。
所以在我還沒站到腳酸時,電池就已經換好了,
老闆還順便用吸塵器清了風扇,用洗潔精擦了擦 MBP 的外觀和螢幕。

從這刻起,我的 macbook pro 2011 又是一尾活龍了!(而且是真的活龍)
忘了裝的是不是原廠的電池了,
不過看在老闆的服務這麼好的份上,
而且價錢又只有原廠的一半,
即使得要一年換一次電池我就甘願。

https://tw.user.bid.yahoo.com/tw/user/Y5622188506

2014/01/05

MacBook Pro 電池壞了,電腦速度蠻超慢

(石門.桃園)

這個問題困擾我兩三個月了。由於電池壞了,整台 MBP 慢得跟十幾年前的電腦一樣,而且還是台裝了 SSD 的高檔貨。網路上看到大部分的文章都是說,要換顆電池,整台電腦又會變得頭好壯壯,但是,才買來兩年的電腦,我實在是不想再去花個幾千塊換電池。而且現在這台 MBP 幾乎都當成桌上型電腦在用了,也不會再移來移去,換顆電池的 CP 值實在是不高。

今天,在網路上找了一下,竟然有辦法可以在電池爛掉的情況下,讓它回復到原有的速度!這真是太好了!馬上試了一下,實際上只不過是把某個設定 CPU 何時該升降速,風扇該運轉的設定檔移走,讓系統找不到,整台電腦就不會那麼卡了。

有需要有人可以參考這個網址:
 http://www.rdoxenham.com/?p=259

2013/09/09

Android Books



It's good to be able to wander in Safari's online shelves and pick up books that I am interested in. Though not having enough time coding, I still managed to quickly take glimpse over two Android books recently. One is 50 Android Hacks, and another one is Android Developer Tools Essential. Both are good to read and gave me some new nuance for my poor Android knowledge.

2013/07/01

Google Reader is going into history today.

I've been using Google Reader for very very long time. It's the most important news resource and knowledge source for me. Now it will be closed soon. Kind of  sad that such a good service will no longer exist.


乩童警探 一二集

接連看了兩集。第一集還算新鮮,到了第二集就看得比較慢了。一來,劇情雖然常會提到乩童,但真的跟乩童又沒有什麼關係。第二集後半大概就猜出是怎麼一回事了,但還是很享受在作者解釋的過程。只是前面舖陳有點久,而且人物有點多,再加上我是斷斷續續的看,看到後來都快忘了誰是誰,或是誰曾經出過什麼...