From: peter@abbnm.com (Peter da Silva)
Subject: Re: Unexpected result from grep
Date: Mon, 22 Dec 2003 21:14:55 +0000 (UTC) [thread overview]
Message-ID: <bs7msf$19vu$1@jeeves.eng.abbnm.com> (raw)
In-Reply-To: 0z_Eb.170955$Eq1.160079@twister.rdc-kc.rr.com
In article <0z_Eb.170955$Eq1.160079@twister.rdc-kc.rr.com>,
Dan Mercer <dmercer@mn.rr.com> wrote:
> Portability using a minimal sh functionality pushes the burden of portability
> from the shell to the OS.
That's one way of looking at it, I suppose. Really, though, that viewpoint
is confusing correlation and causation.
Just because you're running ksh or bash or zsh doesn't mean you're running
a new awk or that perl is installed. Writing a script in a less portable
way, from the point of view of the shell, doesn't provide any guarantee
that all the program invocations in the script are going to work. And
writing it in a more portable way doesn't change the version of awk already
installed on the target system into gawk.
All you can say is that a system with a newer shell installed is more likely
to have newer versions of other programs, but if other parts of the code
are non-portable then all you're doing is hiding any deeper problems
and make it harder to isolate them when they do show up. And in the
meantime you're adding to system complexity by forcing people to install
multiple different shells.
As for using the "#!/bin/ksh" to discourage the use of older shells, you
can get the same results by putting that line there without actually using
a single ksh extension. :)
> It's too bad the POSIX shell group did such a poor job - too much
> infighting from people with vested interests. Personally, I would
> have been perfectly happy had they just said : "We're going to use
> zsh - get over it."
If they had done that then they would have condemned the POSIX shell to
complete instead of marginal irrelevance, since they would have been
even more widely ignored than they are now.
-rwxr-xr-x 2 bin bin 131072 Apr 12 1999 /usr/bin/sh
text data bss dec hex
114688 16384 4752 135824 21290
-rwxr-xr-x 2 bin bin 270336 Apr 12 1999 /usr/bin/ksh
text data bss dec hex
229376 40960 17968 288304 46630
-rwxr-xr-x 1 root system 917504 Nov 23 1999 /usr/local/bin/zsh
text data bss dec hex
598016 73728 48896 720640 aff00
--
I've seen things you people can't imagine. Chimneysweeps on fire over the roofs
of London. I've watched kite-strings glitter in the sun at Hyde Park Gate. All
these things will be lost in time, like chalk-paintings in the rain. `-_-'
Time for your nap. | Peter da Silva | Har du kramat din varg, idag? 'U`
next prev parent reply other threads:[~2003-12-22 21:14 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-11 16:13 Unexpected result from grep Dan
2003-12-11 16:32 ` Jens Schweikhardt
2003-12-11 16:37 ` Chris F.A. Johnson
2003-12-11 16:47 ` Stephane CHAZELAS
2003-12-11 18:24 ` Joseph Dionne
2003-12-12 13:19 ` Dan
2003-12-19 20:11 ` Peter da Silva
2003-12-20 16:13 ` Dan Mercer
2003-12-22 21:14 ` Peter da Silva [this message]
2003-12-23 16:01 ` Dan Mercer
2003-12-23 21:01 ` Peter da Silva
2003-12-23 22:15 ` Dan Mercer
2003-12-25 22:29 ` Peter da Silva
2003-12-24 16:41 ` Stephane CHAZELAS
2003-12-25 22:15 ` Peter da Silva
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox