Tools, glue, scripts, and automation on Unix - Old school stuff

Users browsing this thread: 2 Guest(s)
jkl
Long time nixers
Insert the usual monologue about the decay and, effectively, death of "the tools principle" through the advent of can-do-all text editors here. (I guess I don't really need to explain that.)

On to the text:

Quote:Usually scripts are interpreted, like we said "run-time", rather than
compiled.

For example, the shell is a scripting environment. Perl also, and other
dynamic high level languages, could be considered scripting environments.

Perl might be a bad example since it actually uses a bytecode compiler.

Quote:Pipes were first implemented in UNIX in 1972 by Doug McIlroy. The idea
is simple but powerful: to allow the standard output of the program on
the left side of the pipe to be the standard input of the program on
the right side of it.

That was the second attempt of implementing pipes. Their first approach - which only lasted a couple of months - used "<" and ">" to define the direction.

Quote:This general concept is a trademark features of Unix.

Not anymore: There are blown-up Unix tools (tried Solaris recently?) today while the "KISS" thing had been ported to VMS and other operating systems soon after its invention.

Quote:The RUNOFF of the CTSS was one of the first, if not, computer text
formatting program.

In the modern sense of the word, yes.

Quote:roff and nroff are the successor of the Multics version.

roff already existed in a Multics version.

Quote:However, the pages were only written in runoff since the 4th Unix edition,

Not one single manpage on Unix was written in runoff as runoff never existed on Unix. There was not even a roff command on PDP-7 UNIX. Before he did troff, Joe Ossanna ("jfo") - double-N - implemented his own version of McIlroy's BCPL version of Robert Morris's implementation of RUNOFF named "roff" into V1 UNIX: man(1).

Quote:When roff started being used for manpages it instantly became popular
within Bell Labs patent department

That's what they had planned (as you wrote later). :-)

Quote:dc (...) It's the oldest surviving Unix language.

Depends on how you define a "language". Wouldn't that be B? dc is the oldest surviving interpreted language though.

Quote:It was the first program to be run on the newly acquired PDP-11

According to McIlroy's notes (p. 10), it was the first language to be run there. I could not find a source about whether it was the first program, but Ritchie suggested that it was, in fact, "one of the earliest programs to run on the PDP-11". As they had received their PDP-11/20 in 1970 and Unix ran on it in the same year, I would want to assume that dc predates 1971. Ken Thompson said that they already had a version of it on the PDP-7.

Quote:The first version was written in B, predating the C language, by Robert
Morris and Lorinda Cherry, which are also the author of bc which we'll
tackle in a bit.

Robert Morris was also the "roff" guy from above. The world was small back in the days.

Quote:Dennis Ritchie later on produces a version of ed that Doug McIlroy
described as the "definitive" ed. I can't find much about it but I think
it was a C rewriting.

There were quite some "eds" involved.

Quote:So it is more or less true that ed doesn't have much practical use today
as an interactive program

Essentially having replaced Vim by ed on my servers, I wholeheartedly disagree.

Quote:On the other side Emacs, which the version at the time wasn't a free as
in free beer, would cost hundreds of dollars, and to be clear we're not
talking about GNU Emacs, which didn't appear before 1985, but an earlier
version also called Gosling Emacs or Unipress Emacs.

Gosling Emacs "didn't appear" before 1981, so, in fact, the expensive versions of Emacs were not a thing when vi was published. 1978 already had (versions of) TECO, Emacs's birthplace, as well as Stallman's original MIT Emacs itself which was available at no cost either - we had the topic "everything was free software once" in a previous discussion. Here is a list of free Emacsen.

Quote:For example Minix created a vi clone called Elvis.

Tanenbaum added the third-party Elvis editor to Minix - it was not created "by Minix" although its creator published it to the Minix newsgroup first.

Quote:there's a mode to access the ed features

You cannot access ed features directly, except by calling ed as a subprocess. You can access ex features though, those are different.

About sed's ed compatibility:

Quote:For example, s is for substitution, it is followed by a slash separating
the pattern match (regex) and the string to substitute the match with.

ed does not limit you to the slash character: sxaxe or swawe, whatever works for you, replaces "a" by "e". sed does not support that.

Quote:Historically it was created in April 1976 by Stuart Feldman at Bell labs,
and included in Unix starting with the first edition.

Unlikely, since Unix was in its sixth edition by 1976. PWB/UNIX was not the same thing as "the Unix".

Quote:Today there are ton of other build systems, which I won't cover. Imake,
autoconf, cmake, automake, gnu make, etc..

Covering syntactic difference between BSD make and GNU make could have been interesting though. Portability is a problem.

Other than that, thank you for the podcast.

--
<mort> choosing a terrible license just to be spiteful towards others is possibly the most tux0r thing I've ever seen


Messages In This Thread
RE: Tools, glue, scripts, and automation on Unix - by jkl - 03-03-2018, 02:12 PM