which is the basic differences between the shells?

Polytropon freebsd at edvax.de
Mon Jun 7 18:26:07 UTC 2010

On Sun, 6 Jun 2010 22:06:07 -0600, Chad Perrin <perrin at apotheon.com> wrote:
> On Sun, Jun 06, 2010 at 10:06:28AM -1000, parv at pair.com wrote:
> > 
> > I cannot say about the tcsh features.
> That's kind of a shame, since tcsh is what I prefer these days, having
> long since given up on bash (pretty much immediately after I started
> using FreeBSD as my primary OS instead of bash, and realized I preferred
> the csh-style syntax).

I may use this chance to add that I'm also a fan of FreeBSD's csh
especially from the standpoint of dialog behaviour. For example,
autocompletition is - in my opinion - much better than in bash
(which does force too much interaction).


	$ ls /usr/local/bin/m[tab]
***	[tab]
	Display all 146 possibilities? (y or n)
***	y
	mDNSClientPosix*            moc-qt4*
	mDNSIdentify*               modutil*
***	q
	$ ls /usr/local/bin/m

The "***" marks all unneccessary interaction that interrupts
work flow.

Also, csh's history behaviour is better - again in my opinion.
For example, if you enter "bl" and press the up / down arrow keys,
you can browse all commands that started with "bl", e. g. "bla", 
"bli", "blubb", "blonk" and so on. In bash, you would browse
through *all* commands using the same approach.

I am aware of the fact that most shell behaviour can be configured
or reprogrammed, but I'm just talking about the default settings.

> I've never really tried using vi-mode editing in any shell, despite the
> fact I'm a constant vi user (even a vi gangsta, one might say).  Maybe I
> should some day.  Thus far, though, I don't even know if tcsh supports
> vi-mode editing.

According to "man csh", it is possible:

   The command-line editor (+)
       Command-line  input  can  be edited using key sequences much like those
       used in GNU Emacs or vi(1).  The editor is active only  when  the  edit
       shell  variable  is  set, which it is by default in interactive shells.
       The bindkey builtin can display and change key  bindings.   Emacs-style
       key  bindings are used by default (unless the shell was compiled other-
       wise; see the version shell variable), but bindkey can change  the  key
       bindings to vi-style bindings en masse.

Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...

More information about the freebsd-questions mailing list