Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 20 Sep 1996 07:50:29 -0600 (MDT)
From:      Wes Peters <softweyr@xmission.com>
To:        Randy DuCharme <randyd@nconnect.net>
Cc:        questions@freebsd.org
Subject:   Shells shells shells?
Message-ID:  <199609201350.HAA03020@obie.softweyr.com>
In-Reply-To: <73281000@toto.iv>

next in thread | previous in thread | raw e-mail | index | archive | help
Randy DuCharme writes:
 > [...] I'm wondering...what's the "BEST" shell to use for a person
 > new to UNIX.  (by new I'm implying that I'm unaccustomed to any
 > particular shell and will be learning whatever shell from the
 > ground up).

Bash.  It has all of the features of the Bourne shell (sh) (except,
perhaps, speed), and most of the features of the Korn shell (ksh) and
C shell (csh), and many features none of those have.  It has command
line editing like tcsh, or vi-style line editing for those who want
it, interactive command recall, a history mechanism that makes sense
when you run multiple sessions, and a raft of other features.

The one disadvantage is size:

text    data    bss     dec     hex
225280  12288   45048   282616  44ff8   /bin/csh
270336  16384   44052   330772  50c14   /bin/sh
335872  20480   7236    363588  58c44   /usr/local/bin/bash

Fortunately this doesn't hurt quite so much on FreeBSD, you really
only have one copy of that 330K text segment in memory, regardless of
how many bash sessions you have running.

For writing shell scripts, I usually stick to /bin/sh, as it is the
*most* portable shell across UNIX systems -- they all have at least
that one.  ;^)

-- 
   Wes Peters	|
    Softweyr 	|   Where am I, and what am I doing in this handbasket? 
   Consulting	| 
 softweyr@xmission.com




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199609201350.HAA03020>