[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4779: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4781: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4782: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4783: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3887)
Gentoo Taiwan 討論區 • 檢視主題 - 用screen取代terminal的Tab
1 頁 (共 1 頁)

用screen取代terminal的Tab

文章發表於 : 週五 10月 02, 2009 3:00 pm
pokkys
很多terminal都有tab功能。比方說gnome-terminal或者是ROXTerm。各家有各家的好處,有些功能齊全,有些速度快。不過我都沒在用這種Tab功能。因為screen的功能就非常足夠。

screen,也就是gnu screen,他可以在一個terminal裡面顯示多個page。
圖檔
看起來很漂亮,但是很多人第一次打screen就放棄了,因為沒有設定過的screen什麼東西都沒有。所以這裡提供我的設定檔給各位速成。

使用方法:

1. 把設定檔抓下來,存成.screenrc放在家目錄下。
2. 執行screen
3. 你就會看到只有一個page 的screen
4. 成功

screen的命令大多是先按Ctrl + a 之後再按command,以下用C-a-?表示

* C-a-c : 開一個新的page
* C-a-p : 回到上一個page
* C-a-n : 到下一個page
* C-a-d : 離開screen,但是不關掉screen
* C-a-ESC : 進入buffer模式,可以用方向鍵和Page up and down瀏覽
* C-a-k : 殺掉一個page
* C-a-[1-9]: 跑到第#個page

大概就這樣,記得C-a-d之後會detach。但是執行中的程式並沒有被關掉。之後只要用screen -rd就可以叫回來了。所以你可以拿來掛BT,IRC,BBS or MSN之類的東西,就算把terminal關掉,下次也只要打screen -rd就可以把他們統統叫回來,非常方便。基本上我用過screen之後,我就不會想再用terminal的tab功能了。XD

我的設定檔額外功能:

* C-a-b :將big5轉成UTF-8,適合拿來telnet 看BBS。
* C-a-u : 切回UTF-8
* Ctrl-左右 : 快速切換page

快速切換page很方便,但是需要自己測試一下。

設定檔裡面有很多行bindkey,但是實際上只需要兩行。

Ex: bindkey “^[[5D” prev

我為了不同terminal(gnome-terminal,putty…etc)所設定的。到底要bind哪一個key可以下cat之後,按Ctrl-左右來判斷,不需要的都可以砍掉。
設定檔:

Re: 用screen取代terminal的Tab

文章發表於 : 週五 10月 02, 2009 11:03 pm
jojoyakira
感謝!
這設定檔真好用。 :D

Re: 用screen取代terminal的Tab

文章發表於 : 週六 10月 03, 2009 9:50 am
Jackie

Re: 用screen取代terminal的Tab

文章發表於 : 週日 10月 04, 2009 1:21 pm
pokkys

Re: 用screen取代terminal的Tab

文章發表於 : 週三 10月 07, 2009 10:48 pm
oahong
强烈推荐 tmux 给各位大大,除了 screen 之外,这是一个很不错的选择~

Re: 用screen取代terminal的Tab

文章發表於 : 週四 10月 08, 2009 11:00 pm
jojoyakira

Re: 用screen取代terminal的Tab

文章發表於 : 週五 10月 09, 2009 12:26 am
pokkys