Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!wuarchive!zaphod.mps.ohio-state.edu!tut.cis.ohio-state.edu!ucbvax!ucsfcgl!cca.ucsf.edu!wet!cc From: cc@wet.UUCP (Christopher Cilley) Newsgroups: comp.unix.questions Subject: Re: System V questions Summary: answers for csh Message-ID: <904@wet.UUCP> Date: 2 Jan 90 16:52:25 GMT References: <21916@adm.BRL.MIL> Reply-To: cc@wet.UUCP (Christopher Cilley) Followup-To: comp.unix.questions Distribution: comp.unix.questions Organization: Wetware Diversions, San Francisco Lines: 36 In article <21916@adm.BRL.MIL> herman%nrl.decnet@ccf3.nrl.navy.mil (NRL::HERMAN) asks: > > i) How can I get the prompt to show me the current directory. > > ii) Is there something available in System V which is equivalent to the > 'alias' command available in BSD UNIX. That is, can one define > symbols in a way similar to the way #define defines symbols in C. I can pass along the answers for C-shell (/bin/csh). i) I have the following in my .cshrc in the home directory: # The following sets your prompt to print out the current command number # and working directory. alias cd ' cd \!* ; set prompt = "`pwd` [\\!] " ' This will give output that looks like: /usr/local/lib/elm [23] ii) You can set aliases by just putting them in the .cshrc like this: # Set local aliases. alias h cd $home alias hi history alias chterm 'set TERM=\!* ; setenv TERM \!* ; tput init' alias ll ls -al alias llm 'ls -al \!* | less' alias lc ls -aCF alias psa ps -ef alias mail mailx alias bye logout etc. etc. -- ---------- ---------- ---------- ---------- ---------- Christopher Cilley {ucsfcca|claris}!wet!cc cc@wet.UUCP "Life is uncertain - eat dessert first..." -RJR