今天又 update 一台 Debian Sarge 到 Etch。

結果發現它把預設的編輯器改為 nano。
因為習慣用 vi ,所以,要把它改過來。

可以執行:
# update-alternatives --config editor

There are 4 alternatives which provide `editor'.

Selection Alternative
-----------------------------------------------
1 /bin/ed
*+ 2 /bin/nano
3 /usr/bin/nvi
4 /usr/bin/vim.basic

Press enter to keep the default[*], or type selection number: 4
Using `/usr/bin/vim.basic' to provide `editor'.


這樣就可以啦!

參考來源:
http://www.debianadmin.com/howto-change-default-editor-in-debian-etch.html