cshell 相关

cshell

查看 shell 环境变量

echo $SHELL

prompt 设置

if ($?prompt) then
        set prompt = "%{\033[32m%}%n@%m%{\033[34m%}--> " # 用户名@主机
        # set prompt = "%{\033[92m%}%n@%m%{\033[94m%}--> " # 亮蓝和亮绿
        # set prompt = "%{\033[92m%}%n@%m %~%{\033[94m%}--> " # 用户名@主机 路径
endif

alias ls 'ls --color'

# 终端窗口标题
if ($?TERM) then
  switch ($TERM)
    case xterm*:
        set user = `whoami`
        set host = `hostname`
        echo -n "\033]0;${user}@${host}\007"
        breaksw
  endsw
endif


csh 修改提示符是通过设置 prompt 变量完成

主题:cshell 不用设置主题,直接修改终端的主题,设为护眼就行

posted @ 2025-04-11 09:44  卑以自牧lq  阅读(16)  评论(0)    收藏  举报