id:antipopさんに「tscreenとかtmuxがおすすめ。使ってないけど」と言われたので、とりあえずscreenの設定がそのまま使えるtscreenを使ってみた。
インストール
Mac Portsにはないようなので、ソースからインストール。
% wget http://www.steve.org.uk/Software/tscreen/dist/tscreen-0.4.9.tar.gz % tar zxvf tscreen-0.4.9.tar.gz % cd tscreen-0.4.9 % ./configure % make % sudo make install
あと、.screenrcを.tscreenrcにコピー
cp .screenrc .tscreenrc
設定
tscreenを入れてみた - おもしろwebサービス開発日記にemacsキーバインド風にする設定が書かれていたので、それに従って設定した。screenの設定も奥が深そうだから今度勉強するってことで。これで例えばC-j,C-x,3とかで縦分割ができたりします。便利!!
escape ^Jj
hardstatus alwayslastline "%`%-w%{=b bw}%n %t%{-}%+w"
defscrollback 10000
startup_message off
bind -c REGION o focus down
bind -c REGION p focus up
bind -c REGION 0 remove
bind -c REGION 1 only
bind -c REGION 2 split
bind -c REGION 3 split -v
bind -c REGION \^ resize +2
bind -c REGION } resize +2
bind -c REGION { resize -2
bind ^x command -c REGION