• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录

SOC/IP验证工程师

  • 博客园
  • 联系
  • 订阅
  • 管理

公告

View Post

cshrc的设置实例

##### An example .cshrc file for CSCI 3308 for use in the CSEL #####
#
# This file (.cshrc) is run every time you spawn a tcsh shell.
# This includes every time you open a new Terminal window
# (as this action spawns a new shell)
#
####################################################################
#
# Set the ARCH environment variable before setting the path;
# This allows you to add architecture-specific directories
# to your path

if (! $?ARCH) then
    setenv ARCH `/usr/local/bin/arch`
endif

if (! $?UNAME) then
    setenv UNAME `uname`
endif

set packages = ( netscape gcc-3.3 j2sdk Acrobat mathematica news )
setenv MANPATH /tools/cs/man

set pathadd = ""
foreach p ( $packages )
    if ( -d /tools/cs/$p ) then
    set pathadd = ( $pathadd /tools/cs/$p/bin )
    setenv MANPATH ${MANPATH}:/tools/cs/$p/man
    endif
end

if ( -d /usr/share/man ) then
    setenv MANPATH ${MANPATH}:/usr/share/man
else
    setenv MANPATH ${MANPATH}:/usr/man
endif

# first merge $path and $pathadd
set path = ( $pathadd $path )

# then get rid of pathadd variable
unset pathadd

# now add additional paths
set path = ( $HOME/bin $path )

setenv MANPATH ${MANPATH}:/usr/local/man:/usr/local/X11/man

# basic info about the host/user
if (! $?USER) then
    setenv USER `whoami`
endif
setenv USER alfred//设置环境变量
setenv PATH /proj/scripts/bin:$PATH//增加环境变量文件夹

if (! $?HOST) then
    setenv HOST `hostname`
endif

# Set the editor to use (usually vi).
setenv EDITOR vi

setenv PAGER less

# how many commands to keep in the history database
set history = 200
set savehist = 800 merge

# standard csh features
set filec           # enable filename completion
set notify          # report status of background jobs immediately
set noclobber       # don't clobber existing files
set nomatch         # not an error if '*' matches nothing

# tcsh-specific features
if ($?tcsh != 0) then
    set prompt="[%m:%c3] %n % "
    limit coredumpsize 1k
    unset autologout    # don't log me off after a set idle time
    set echo_style both # emulate bsd and sysV /bin/echo's
    set addsuffix   # / on dir during file name completion
    set ampm        # show times in 12 hr. format
    set autolist    # list possibilities for file name completion
    set autoexpand  # expand history automatically with 
endif

# Some useful Aliases.
alias ls "ls -F"
alias rm "rm -i"
alias mv "mv -i"
alias cp "cp -i"

# Unalias some non-useful aliases
unalias l.
unalias ll
unalias mc

alias cd 'cd !*; ll -color'

posted on 2022-03-18 16:42  SOC验证工程师  阅读(659)  评论(0)    收藏  举报

刷新页面返回顶部
 
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3