- csh weirdness

Eric Promislow promislo at qucis.UUCP
Tue Apr 1 10:45:25 AEST 1986


	I think the latest debate on problems with struggling with the
vagaries of C-shell programming points out a couple of problems many
people find:

		1.) First, the Berekely people seem to have a propensity towards
documenting everything once.  Exactly once.  As Greg mentioned, I recall
reading somewhere that the shell won't do a history substitution on an
exclamation point if it is followed by white space or a newline.  I
don't know where I read it (probably in the csh manual), but I know it
wasn't mentioned in the test (1) page.  This is the sort of thing that
causes people to dump on Unix (and C) for overloading operators.

		2.) Those beginners with the fairly common misfortune of not 
having a guru around have a fairly vast choice of books to look at on
getting started, all assuming that the reader is using the Bourne shell
(okay, this holds at least for all the books I've looked at).  I've
used about six different Unix systems, III, V, and 4.2, and nobody used
the Bourne shell on it.  I'm beginning to suspect the authors skip the
C-shell (with perhaps a perfunctory aside towards mentioning the '%'
prompt) exactly because of the sort of complications Messrs. Dunn and
Woods pointed out.

		If anyone out there has compiled a short but complete guide to
effective  C-shell programming and usage, we sure could use a copy
around here.

	As for my advice, I learned the history mechanism largely by
trial and error, appreciate the escape-key completion (documented
nowhere, as far as I can tell) and job-control features, and do all my
shell programming with the Bourne shell.  I don't see any reason
to write scripts in the C-shell, except for the aforementioned
exercising of masochistic tendencies.

	Eric Promislow,
	Queen's University, Kingston, Ontario

	( ...utcsri!ihnp4!promislo )



More information about the Comp.bugs.4bsd.ucb-fixes mailing list