[TUHS] origin of the name 'glob'
rminnich at gmail.com
Mon Jul 10 02:38:10 AEST 2017
back when glob was a separate binary it was pretty easy to spawn glob from
things other than the shell, which was kind of neat. You'd get shell
globbing in anything. But jamming globbing into the shell was overall
probably a good thing ...
On Sun, Jul 9, 2017 at 7:53 AM Steve Johnson <scj at yaccman.com> wrote:
> I never asked the originators. In fact, I don't think I've ever used glob
> outside of the shell...
> It's interesting to contemplate how the world might be different if we had
> used regular expressions consistently in the shell as well as the
> editor(s). We could have picked some other character like : to indicate
> the file extension. I suspect we would have had regular expressions built
> into all kinds of things...
> ----- Original Message -----
> "Doug McIlroy" <doug at cs.dartmouth.edu>
> <tuhs at minnie.tuhs.org>
> Sun, 09 Jul 2017 08:26:56 -0400
> Re: [TUHS] origin of the name 'glob'
> Glob was an an accident. When Ken and Dennis wanted to put wildcards
> (an anachronistic word--it wasn't used in the Unix lab at the time)
> into the shell, there wasn't room, so they came up with the clever hack
> of calling another process to do the work.
> I have always understood that glob meant global because commands like
> rm *
> would be applied to every file in a directory. A relationship to ed's
> g command was clear, but not primary in my mind.
> One curious fact is that from day one the word hase been pronounced glob,
> not globe. (By contrast, creat has been variously pronounced cree-at
> and create.) It is also interesting to speculate on whether there would
> be a glob library routine in Linux had glob only been an identifier in
> sh.c rather than an entry in /bin.
> I believe the simple * was borrowed from somewhere else. If the g command
> had been the driving model, glob would probably have had ? and ?*, not
> ? and *. (It couldn't use ed's . because . was ubiquitous in file names.)
> My etymology is somewhat different from Steve's. But I never asked the
> originator(s). Steve, did you?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the TUHS