views:

331

answers:

4

What's in your .cshrc that gives you total command of the C shell? Aliases welcome too!

One technique or command per answer.

+5  A: 
exec /bin/ksh

See: Csh Programming Consdered Harmful

See also: What Linux shell should I use?

Jonathan Leffler
A: 

Simple really....

exec bash
dsm
+2  A: 
alias   m0      'set d0 = `pwd`'
alias   m1      'set d1 = `pwd`'
...
alias   g0      'cd $d0'
alias   g1      'cd $d1'
...

Typing m0 saves the current working directory (in d0) and g0 returns to that directory.

J. A. Faucett
You know about 'pushd' and 'popd'? Similar to what you have except you don't need to have a fixed number of aliases: your stack can get arbitrarily deep.
quark
Thanks, I had forgotten about these. The drawback is that it's a stack. I tend to move around several directories in random order. As far as the fixed number issue, I can't remember more than about five anyway. Also the d0... can be used in other commands, like "cp $d1/myfile $d2".
J. A. Faucett
+1  A: 

exec /bin/zsh

Oh z shell, what would I do without you?

metao