2012-02-05 34 views
0

最近我的bash經常進入我不明白的狀態(debian squeeze system)。例如,啓動新的xterm後,Control-l會在屏幕上打印「^ L」而不是清除它。這發生在「新鮮」xtermbash以及dash(甚至xterm -e /bin/dash)。另外,reset從來沒有幫助。奇怪的終端模式,bash的錯誤?

相比之下,在ssh'另一個盒子,Control-l做我的期望。

有人可以對這種非常奇怪的行爲給我一個有根據的猜測(我的Unix知識不能幫助)嗎?

回答

2

對不起,我發現了。 set -o vi是罪魁禍首,至於bash。至於破折號,這只是正常的行爲...一直很難。

0

檢查stty -a輸出和$TERM變量。 $TERM應該是「xterm」或「xterm-color」

+0

'$ TERM'是「xterm」。什麼應該「stty -a」收益? (對不起,在下一條評論中長輸出...) – 2012-02-05 14:03:44

+0

stty -a:速度38400波特;行24;列80; line = 0; intr =^C; quit =^\;擦除= ^?; kill =^U; eof =^D; eol = ; eol2 = ; swtch = ; start =^Q; stop =^S; susp =^Z; rprnt =^R; werase =^W; lnext =^V; flush =^O; min = 1;時間= 0; -parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts -ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc -ixany -imaxbel iutf8 opost -olcuc -ocrnl onlcr -onocr - onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0 isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop -echoprt echoctl echoke – 2012-02-05 14:03:58