alias setprompt 'set prompt="\\This provides a space on one line, the user id@machine: path on the second line and the command number (used for reference, such as !32) on the third line. All commands appear at the same distance from the left (commands 1 thru 99) (100-999) etc. That is what makes this usefull. I can always see what the last command was when I scroll back up.
`whoami`@`uname -n`: `pwd`\\
[\\!] "'
if ( $?prompt ) then # shell is interactive.
alias cd 'cd \!*; setprompt'
endif
cd
You can leave out the uname -n part if you are on a single machine a lot (such as on your Mac) since this will "return" localhost and is not really useful for identifying your Mac. (You know you are alone and on 1 machine). In a multiple machine environment, this is handy to know which machine you are logged into. You can add other items in the if--endif to satisfy your needs (I have an alias for history set to h, for example). The reason you need the if--endif is so if you log in with a batch command, the prompt doesn't get set to confuse your commands in batch mode.
On a SUN UNIX box I have included spaces after the colon and after the final [\\!]. This allows selecting the path or command with the mouse (for copy/paste) easier for modification. (If your environment is set right, you can double-click on the path or command with the left mouse button and paste with the middle mouse button. This is great for repeat or simple modifing paths without knowing or using vi if your shell isn't bsh or tcsh)
Just so there is no confusion: the first quote is a regular quote, (middle row usually). The quotes around whoami, uname -n and pwd are back quotes and there is a double quote and single regular quote after the [\\!] . There are regular quotes around the cd \!*; setprompt in the if ... endif. The setprompt name is a user supplied name, you can use anything.

