Subject: Re: CVS commit: basesrc/bin/ksh
To: NetBSD Userlevel Technical Discussion List <tech-userlevel@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: tech-userlevel
Date: 10/16/2002 19:30:22
>>> Sure there's tcsh, but has it really added anything fundamental
>>> (beyond command-line editing, of course) that its users now use
>>> widely and agree is essential for all "csh"-like shells?
>> Not that I know of - but in my opinion, that weakens, rather than
>> strengthens, your argument, because it means that csh is
>> satisfactory as it stands, rather than needing constant improvement.
> Obviously for your argument to have any meaning we would have to find
> some significant numbers of users who are (still?) actively using csh
> as an important (to them, at least) and maybe even primary scripting
> language.

And we (finally!) begin to see where you are arguing from: a position
that the appropriate metric to judge a shell's goodness is based on its
use as a scripting language.

> I am indeed talking about the language since of course the user
> interface of the interpreter can be almost trivially re-grafted onto
> any interpreter

Indeed?  I challenge you, then, to configure /bin/sh, or /bin/ksh for
that matter, to make it look like csh.

Don't forget to include handling >& and |&, distinguishing between
shell variables and environment variables, and handling aliases
containing history references.  (Providing an "alias" that massages the
alias into a shell function is acceptable, provided you preserve the
semantics.)

Then, I challenge, nay, I *defy*, you to do so "almost trivially".

> You yourself go on to agree that csh is a horrible programming
> language, so if it were to be used in any significant way then it
> could only be expected that there really would be desparate need for
> constant and major improvement in the language.

Only if "any significant way" necessarily implies its use as a
scripting language.

My login shell is a csh derivative.  But I never use it for scripts;
with only two exceptions, all my shell scripts are sh scripts.  (The
two exceptions are my .cshrc and .login.)

>> csh works very well indeed for its target, interactive use.
> The point is that ksh (and in particular pdksh) works even better for
> interactive use, [...]

Not for me.  You seem to be under some kind of impression that sh and
csh have no significant differences for interactive use, aside from
command-line editing.  This may be true for your value of
"significant", but is definitely not so for mine.

/~\ The ASCII				der Mouse
\ / Ribbon Campaign
 X  Against HTML	       mouse@rodents.montreal.qc.ca
/ \ Email!	     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B