home *** CD-ROM | disk | FTP | other *** search
- #=======================================================================#
- #
- # File: .cshrc
- # Support: .setheaders (support file for an alias)
- # Descrip: (with humour:) Sample .cshrc file for new users.
- # Author: Christoph. A. North-Keys (erlkonig@snowwhite)
- # Rev: 3.1 (Mittwoch.d.30.Maerz.1988)
- #
- #=======================================================================#
-
- set term = "$term"
- if !($?LOGGED) source ~/.login
-
- set cdpath = (. ~ ~/aux ~/Critters)
- set X10path = /usr/new
- set X11path = (/usr/local/X11 /usr/new)
- alias pathset 'set path=(. ~/bin /bin /usr/bin /usr/local /usr/lib `echo $Xpath` /usr/ucb /usr/5bin /usr/games) ; rehash'
- alias X10set 'set Xpath = "$X10path" ; pathset'
- alias X11set 'set Xpath = "$X11path" ; pathset'
-
- X11set
-
- if ($?USER == 0 || $?prompt == 0) exit
-
- echo "Entering C Shell"
-
- set history = 100 savehist = 50
- set nobeep
-
- # Set search directories
- set cdpath = (. ~)
- set path=(. ~/bin /bin /usr/bin /usr/local /usr/lib /usr/ucb /usr/5bin /usr/games)
- alias m 'less'
- alias pg 'pg -c -n -p " Page=(%d):"'
- alias h 'history -r | m'
- alias self 'source ~/.cshrc'
- alias pp 'psplot \!* | lpr -Plw1 -h'
- alias cl clear
-
- setenv TTY `tty`
- set filec
- set notify
- set prompt="$HOST-\!% "
- set prompt="`echo $HOST|sed 's/.cc.utexas.edu%//'`-\!% "
-
- if ($TTY != '/dev/console') then
- if (($TERM == 'sun-cmd') || ($TERM == 'sun') || \
- ($term == 'sun-cmd') || ($term == 'sun')) then
- echo 'Assuming SunWindows environment.'
- setenv HEADERS "sunheaders"
- else #Xwindows
- echo 'Assuming Xwindows environment; use noheaders to cancel.'
- setenv HEADERS "xheaders"
- setenv SCREEN "0"
- setenv DPY "0"
- setenv DISPLAYMACH $HOST
- if ($?DISPLAY == 0) then
- setenv SCREEN "0"
- setenv DISPLAY $HOST":"$DPY"."$SCREEN
- endif
- setenv RESOURCE_MANAGER "$HOME/.X11defaults"
- echo 'Assuming Xserver '$HOST','
- echo ' Xdisplay '$DISPLAY','
- echo ' Xdpy '$DPY','
- echo ' Xscreen '$SCREEN', use xdisp to change.'
- endif
- else
- echo 'Assuming minimal raw terminal environment.'
- setenv HEADERS "noheaders"
- endif
-
-
- alias h 'history -r'
- alias pwd 'echo $cwd'
- alias . pwd
- alias say 'echo "\!*"'
- alias cd 'cd \!*; echo -n "]l $cwd \"'
- alias rrlogin "echo -n ']l \!* '; rlogin \!*"
-
- # ...more
-
- alias setheaders 'setenv HEADERS \!* ; source ~/.setheaders'
- setheaders $HEADERS
-
- alias st 'suntools -i'
- alias sou source
- alias ex 'chmod +x'
- alias key 'man -k'
-
- # Route file to laser writer
- alias [] 'lpr -Plw\!*'
-
- # Queries about laser writer
- alias []? 'lpq -Plw\!*'
- # [] commands with special formatting--from usernote
- alias [m] 'ptroff -man -Plw\!*'
-
- # Name present directory and describe members
- alias LI 'say listing files \!* ; ls -FlAgs \!* ; pwd'
- alias L 'say listing files \!* ; ls -Fs \!* ; pwd'
- alias l 'say listing files \!* ; ls -Fa \!* ; pwd'
- alias li 'say listing files \!* ; ls -Flags \!* ; pwd'
-
- alias lf 'say listing dir/file \!* ; ls -asgldF \!* ; pwd'
- alias ]d 'pushd \!* ; l'
- alias ]dq 'pushd \!* ; pwd'
- alias [d 'popd ; l'
- alias [dq 'popd ; pwd'
- alias . 'pwd'
-
- # File storage management
- alias q 'say quotas for $user ; quota -v ; pwd'
-
- # Move to auxiliary directory and ...
- alias am 'if (-e ~/aux/\!^) set preaux = $cwd ; cd ~/aux/\!^ ; pwd'
- alias ab 'cd $preaux ; pwd'
-
- # Commands supporting fast moves to key directories
- alias Xc ']d ~/Xconq/c'
- alias M ']d ~/Critters/MentalArmor'
-
- # Move (direct, directory) to given dir, name it and list
- alias md 'cd \!* ; l'
- alias mq 'cd \!* ; pwd'
-
- # Move up to parent dir, name it and ls
- alias mu 'cd .. ; l'
-
- # Cleanup command
- alias ~~ 'say killing files in $cwd ; rm -i .*~ .*% .*OLD .*old *~ *% *OLD *old #*# ; say done killing files in $cwd ; sleep 1 ; pwd'
-
- # Add ability to run direct scripts without reshell NOT COMMAND
- alias shell /bin/csh -f
-
- # Auto-select suntools background
- alias pictools 'suntools -background ~/rasters/\!*.ras -toggle_enable'
- alias pictwols 'suntools -pattern ~/images/tess/\!:1.icon -background ~/rasters/\!:2.ras -toggle_enable'
-
- # Clear screen
- alias . pwd
-
- # Specialized window variations
- if ($term != 'sun-cmd') set filec
- alias wob echo -n "\[q"
- alias bow echo -n "\[p"
- umask 22
- # Section concerning Xwindows
- alias xbg 'xsetroot -bitmap ~/rasters/\!*.ras'
- alias xdisp 'setenv DISPLAYMACH \!:1 ; setenv SCREEN \!:2 ; setenv DISPLAY $DISPLAYMACH":"$SCREEN'
- alias Xfd 'xfd $cwd/\!*'
-
- # Conclusion and note display
- alias note 'say notepad ; vi ~/.notes/\!* ; pwd'
- alias notes 'say notepads ; li ~/.notes'
- alias note? 'say note on \!* ; cat ~/.notes/\!* ; pwd'
-
- # Terminal aids
- alias rs 'resize >/dev/null'
- alias se 'tset -e'
- alias SE 'se ; rs ; clear ; pwd'
- alias hp 'say configuring to hp \!:1 ; X10set ; SE ; xdisp \!:1 \!:2 ; setenv XENVIRONMENT .Xhp'
- alias sun 'say configuring to sun \!:1 ; X11set ; xdisp \!:1 \!:2 ; setenv XENVIRONMENT .Xsun'
-
- #####
- pwd
-
-
- ########################################### End of .cshrc #####################
-
-