why csh?

Hi all,
I'm just curious why FreeBSD is using csh as the shell for root. Is there any historical reason or are there technical ones?
 
As far as I know it's historical. Also note that for instance bash is GPL'ed and can therefor never be part of the base OS.
 
SirDice said:
As far as I know it's historical. Also note that for instance bash is GPL'ed and can therefor never be part of the base OS.

Yes I know about the license issue, I was just thinking about a Bourne shell.
 
The 'classic' bourne shell is good for scripting but using it interactively is a royal pain in the butt. The C-Shells are a pain to script but are good for interactive use.
 
Sorry, I don't understand why c-shell is better than bourne for interactive use. Can you elaborate a bit more? I'm just curious...
 
Tab-completion, history and a few other things. Just set your shell to /bin/sh for a while then switch to /bin/tcsh. You'll notice the differences soon enough ;)
 
csh is a great interactive shell and ash is great for scripting. Virtually anything else has a dependency bloat/larger memory footprint or is license-incompatible.
 
fluca1978 said:
Sorry, I don't understand why c-shell is better than bourne for interactive use. Can you elaborate a bit more? I'm just curious...

In the late 70's Bill Joy made the first distro at Berkeley( i.e. BSD1)

He endowed bell labs unix with ex, vi, and csh. Patches where sent back and forth. One could almost state that he also was the first system admin. Joy's csh had interactive features the thompson shell and bourne shell did not have. As it's been mentioned shell history and tab complete was one of them. I am not sure if external commands where internalized at the time but bourne was all external at first (i.e. while, if where programs in /sbin and [ and test where actual hard links.)

Since ksh, zsh and even bash are posix compliant shells you can install those through ports if you prefer not to use csh or ash. In fact from a earlier thread it would be my observation that most people install one of these shells as their user, use (t)csh on the system as root and write scripts to utilize Almquist's Bourne shell.

Also older users that started off with it will prefer csh for their users and there are a couple threads on usage and customization for user level on this forum.

I hope my information is helpful. I'm a hack historian when it comes to BSD.
 
Back
Top