2013年4月16日 星期二

MacVim plugin (持續更新中...)

在MacVim是一個非常強大的編輯器

他強大之處就是可以plugin套件,經過學長推薦有幾該個還不錯放在上面


ctrlp.vim
https://github.com/kien/ctrlp.vim
https://blog.othree.net/log/2012/11/10/ctrlpvim/


ZenCoding.vim
https://github.com/mattn/zencoding-vim
http://nootn.com/blog/Tool/23/
http://www.zfanw.com/blog/zencoding-vim-tutorial-chinese.html


nerdcommenter
可對程式碼做註解
使用方法可以參考這裡


vim-powerline
可以顯示漂亮的介面
https://github.com/Lokaltog/vim-powerline


snipmate (這個大大的推薦)
這個可以針對不同的附檔名,使用tab鍵快速產生code
http://www.vim.org/scripts/script.php?script_id=2540


vim-css-color
可以在css下對應color顯示
https://github.com/ap/vim-css-color


surround
方便的編輯器,可以去做修改刪除的功能
https://github.com/tpope/vim-surround


NERDtree
檔案編輯器
http://www.vim.org/scripts/script.php?script_id=1658


SuperTab
只要按Tab就可以呼叫最近使用的變數
http://www.vim.org/scripts/script.php?script_id=1643


PIV
這個對於php開發者很重要,不僅可以縮程式碼最重要的是IDE只要
在-> or :: 輸入

<C-X><C-O>

就可以幫你找對應的函式



參考連結及說明:
http://blog.eddie.com.tw/2012/06/01/screencast-3-vim-plugins/







iTerm2

使用了幾天Mac 常常使用command line(我的好朋友阿!)

卻沒有快捷鍵可以馬上呼叫,最近的還只能呼叫到應用程式,還要經過點選等等等等步驟...

實在讓人有點不便

經過學長的推薦, iTerm2實在是太方便而且又可以馬上呼叫,真的是利器


連結在下面


關於iTerm2一些基本設定可以參考這邊

http://loukafai.blogspot.tw/2012/05/iterm2.html

Eclipse Retina

在Retina上去執行Eclipse那畫面真的還蠻不好看

搜尋了一下只要做幾個步驟就可以支援

mvim ~/{存放路徑}/eclipse/Eclipse.app/Contents/Info.plist

接著在倒數第二行加入幾行,記住不能有空白!

NSHighResolutionCapable


參考資料:
http://bbs.weiphone.com/read-htm-tid-5031366.html


Install MAMP Development stack on Mountain Lion using MacPorts

這是一篇從網路上轉載的別人寫好了MAMP(Mac, Apache, MySQL, PHP)使用MacPorts來完成

因為Mac本身就有預載Apache, PHP,不過版本可能不是最新的

前半步驟都在先更新軟體

接下來在做設定

大家可以參考下面的連結:
https://gist.github.com/TeamOneJ/4210358
http://2tbsp.com/content/install_apache_2_and_php_5_macports

在Mac上使用PageUp/Down, Home, End

在Mac上的terminal使用vim的時候

使用PageUp/Down, Home, End 不是針對vim, 而是整個terminal都跳

可以設定下面去讓他不會亂跳



打開 terminal -> Preferences -> Settings -> Keyboard
增加以下四個 Key / Action

home           \033[1~
end              \033[4~
page up       \033[5~
page down   \033[6~


接著只要搭配 fn + 上下左右鍵 就可以了


參考連結:
http://trully622.blogspot.tw/2012/01/mac-vim-pagedown-pageup-home-end.htmlterminal