[nSLUG] Re: Plems with Linux etch

Mike Spencer mspencer at tallships.ca
Fri Aug 24 17:20:09 ADT 2007


gnwiii quoth:

> Please read:
>
> Subject: Csh Programming Considered Harmful

Ahem.  Cough.  Where's the smiley, George?  8-)

Yes, I read that way back when it first appeared on the net.  Indeed,
I had at that time already encountered one of the shortcomings of csh
when I cluelessly tried something like:

    find / -name 'foo*' -print

on a file system that was mounted on AFS.  Do you have *any idea* how
many permission-denied directories are mounted on /afs/*.*.tld/* ?
Yow!  Not to mention the network delays while scanning all of
/afs/athena.mit.edu, /afs/cs.cmu.edu, /afs/*.umich.edu etc. etc.

D.> But with all due respect, Mike stated that he used bash when root,
D.> or when scripting (or at least, script hacking).

Yeah, so there! ;-) Actually, I do have the O'Reilly fish book [1] so
I do RTFM.  I'm just more comfortable with the csh syntax. [2] As a rule,
if I want to script something for which tcsh proves to be too weak,
I'll take it to Perl or even C.  

D.> My biggest pet peeve about tcsh: [command line editing differences]

I do the majority of interactive tcsh command line stuff from within
an Emacs shell buffer in order to have (effectively) infinite
scrollback and just use emacs keystrokes to edit the command line.
Switch to a bare xterm or console only when TERM=dumb isn't good
enough. 

That said, maybe I should bring some examples of advanced bash
redrection to the next install/whatever fest and see if someone will
tutor me on how it works.  I understand the basic concepts, of course,
but, in reading, say, a .configure for a big package, I find
redirection constructs that I just can't follow.


- Mike


[1] Since 2000.  But I've had G&P Anderson's "Unix C Shell Field Guide"
    since 1989.  So csh is ahead by a decade in my cognitive bricklaying.

[2] Does there really have to be a *command* named "[" (/usr/bin/[) in
    order to make the delimiters in bash work right?  Gak!  Why don't
    we do that with *all* the ASCII punctuation so that smileys and
    ASCII art will actually execute?  And didn't /usr/bin/[ used to be
    a symlink to /usr/bin/test?  But now it's not and there's no
    manpage for '[' (in my distro, anyhow).


-- 
Michael Spencer                  Nova Scotia, Canada       .~. 
                                                           /V\ 
mspencer at tallships.ca                                     /( )\
http://home.tallships.ca/mspencer/                        ^^-^^



More information about the nSLUG mailing list