设置 GNU 屏幕背景颜色

设置 GNU 屏幕背景颜色

我希望屏幕在启动时改变终端(xterm)的背景颜色。

我想要一种快速确定我是否在屏幕上的方法。我经常使用 shh 工作,但 shh 经常崩溃。我开始使用 screen 是为了不丢失我的工作。但是,我不希望 screen 在 ssh 到机器时自动启动,因为我可能想用screen -listorscreen -r代替。因此,我需要一些东西来提醒我我不在 screen 中,如果连接断开,我的工作(尤其是正在运行的应用程序)可能会丢失。

我有 xterm 并且我使用ssh -XY,如果相关的话。

答案1

这不会改变背景颜色,但是我有一个 screenrc 文件,它会在底部放置一个状态行,这样当您在屏幕上时就会很明显:

要点如下:https://gist.github.com/cwacek/5724875

# Turn off that annoying start up message
startup_message off

# Turn the even more annoying whole-screen-flash-on-tab-complete "feature"
vbell off

terminfo xterm-color hs@:cs=\E[%i%p1%d;%p2%dr:im=\E[4h:ei=\E[4l
term xterm-color

# Window list at the bottom. hostname, centered tabs and redmarked active windows:
hardstatus alwayslastline
hardstatus string '%{= kG}[ %{G}%H %{g}][%= %{= kw}%?%-Lw%?%{r}(%{W}%n*%f%t%?(%u)%?%{r})%{w}%?%+Lw%?%?%= %{g}][%{B} %d/%m %{W}%c %{g}]'

相关内容