2013年3月29日 星期五

rsync on different ssh port

$ rsync -av --progress --rsh='ssh -p23' somefile user@host:somedir/




Reference :
rsync +ssh on different port?

Windows 無法開啟我的電腦 -> 內容

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer

Data Type: REG_DWORD [Dword Value] // Value Name: NoPropertiesMyComputer

Value Data: [0 - Display Properties / 1 - Hide Properties]




Reference :
Enable/Disable System Properties Access from My Computer

Windows 無法使用 Crtl+Shift 切換輸入法

Start -> Run -> regedit

HKEY_CURRENT_USER\Keyboard Layout\Toggle
Language Hotkey = 1



Value
Meaning
1
Key Sequence for Toggle enabled: LEFT ALT+SHIFT is set (standard value)
2
Key Sequence for Toggle enabled: CTRL+SHIFT.
3
Key Sequences disabled.
4
When default locale is Thai the accent grave key is set for toggle, otherwise it’s disabled.





Reference :
How-to add Keyboard layouts to the language bar. | RES Software Blog

Windows 顯示電腦資訊

我的電腦 -> 內容
sysdm.cpl


dxdiag


msinfo32

2013年3月28日 星期四

vim 使用 tabular 對齊內容

安裝:

如果已經安裝過 pathogen,則直接下載 tabular 到 ~/.vim/bundle 資料夾就可以嘍

$ mkdir -p ~/.vim/bundle
$ cd ~/.vim/bundle
$ git clone git://github.com/godlygeek/tabular.git


使用 :
|start|eat|left|
|12|5|7|
|20|5|15|

要將此資料整理的話,則在編輯器輸入
:Tab/|

 | start | eat | left |
 | 12    | 5    | 7   |
 | 20    | 5    | 15 |




Reference :
godlygeek/tabular · GitHub
Vim 程式撰寫排版用 Plugin - Tabular | Tsung's Blog

vim 安裝 pathogen 套件管理工具

下載 pathogen 到 ~/.vim/autoload/pathogen.vim
$ mkdir -p ~/.vim/autoload ~/.vim/bundle
$ curl -Sso ~/.vim/autoload/pathogen.vim https://raw.github.com/tpope/vim-pathogen/master/autoload/pathogen.vim


在 ~/.vimrc 最前面加入這一行
$ vi ~/.vimrc
execute pathogen#infect() 




Reference :
tpope/vim-pathogen · GitHub 
Vim 插件管理工具 pathogen - DaNmarner的中文博客