A Generation Lost in the Bazaar - Poul-Henning Kamp article

Christopher Browne cbbrowne-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org
Thu Aug 23 20:56:37 UTC 2012


On Thu, Aug 23, 2012 at 3:48 PM, Ben Walton <bdwalton-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org> wrote:
> Having interacted with the coreutils (and the underpinning gnulib)
> folks a bit, I'd almost bet that a new option as opposed to changing
> the meaning of an existing one is the only way forward there.  Getting
> any new option introduced to the coreutils programs requires a well
> written proposal and most of the time the code to back it. :)

My sense on this is that it would be nice if only we could step back
in time and eliminate some of the usages of /bin/ls, and be able to
change its behaviour to be a bit more sensible.

Rob Pike recently (January) twittered something a bit analogous about rm:

Rob Pike ‏@rob_pike
rm: dir: is a directory. Seriously, guys? It's 2012 and rm still can't
remove a directory? You should be ashamed.

This gripe turned into a big "oh, but POSIX doesn't specify it that
way!" fight.  Or, to quote him directly:

"Most of the responses were of three forms: teaching how to use rm,
which I already know how to do, or telling me to setup an alias for rm
-r (which is dangerous and not at all what I want), or telling me it's
necessary for compatibility. My point was not made, but then I didn't
really expect it to be."

What he *really* meant, that it's safe and easy to change rm to remove
an empty directory without requiring flags and without giving an error
that reminds me to run a different command, rmdir.

Unfortunately, "the horse has long, long, long, long bolted."  People
are *so* attached to thinking that directory deletion and file
deletion require different commands, or that /bin/ls behaves in a
given way that we probably have to treat these behaviours as givens
that Can Not Be Changed despite being pretty stupid.

More entertaining was the discovery that .hiding .files .by .putting
.a .dot .on .the .front represents an outright bug that falls from a
bad string comparison when looking for directories that was introduced
in System 2, and which persists to this day.

Either Ken or Dennis made this mistake, of coding (in assembler) the
equivalent of:
   if (name[0] == '.') continue;
rather than
   if (strcmp(name, ".") == 0 || strcmp(name, "..") == 0) continue;

People started using hidden files for things, going as far as the
fictional case, in DecWars, where Con Solo used this bug to hide the
heroes from the Administrative Flunkies, and so we can't get rid of
that blemish.

These are very much "Bazaar" bits, and we've got plenty of them.  And
it takes some "cathedralizing" to clean them up that amounts to
heading over to the Plan 9 'ghetto', or something of the sort.  As
much as there are attractive things about Plan 9, there's no port of
Firefox or Chrome, so most people find that an unacceptable choice.
-- 
When confronted by a difficult problem, solve it by reducing it to the
question, "How would the Lone Ranger handle this?"
--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list