David F. here, with the best true Unix command-name story ever: In the late 1980's, Frame Technology had 50 or 100 employees, and as our product ran on Sun 3/50 workstations, not only the engineers, but many of the admins had them; and of course they all ran the SunOS version of Unix.
One day, Laurie S. from the business side came over to ask me for some help with her system: "I think I've filled up my disk, but how can I find out?" "Well, the 'df' command will show you that info." "But," she replied, "won't that just show me the files in your home directory?" "My home directory??? Why would it do that?" "Well, my initials are LS and that shows my files, and DF are your initials, so that should show your files."
At Sun there was a salesperson, formerly of DEC, who had been taught, in DEC salestraining, that PDP (as in PDP-11/70) stood for “Pink and Dark Purple”, so they could recognize their machines in the lab.
The one major thing I really like about the terseness of these commands is that, although they have a steeper learning curve at first, once you learn them --- which happens quickly with repeated use --- they feel very natural and you use them almost as if they're an extension of English, like a special dialect; talking with coworkers, we use words like "cat", "grep", "ls", "sudo", etc. as verbs.
Contrast this with the verbosity of more "modern" command languages like Powershell: while those may be a bit easier to understand the very first time, every time thereafter it feels like you're talking in a language where every word is a minimum of 10 letters and two syllables long. The mental overhead is far higher.
I've always remembered "bss" as the "bull-shit segment" --- because it initially doesn't have any useful content.
The commands you list aren't too bad because they get quickly learned through use. And "grep" at least is pronounceable and feels strangely apt as a command name.
In general though I think the terseness of the standard Unix commands is a problem, particularly for less often used commands. Even after many years of using them I still get "du" and "df" confused, for example.
"Disk usage" could plausibly be the command that tells you how much space you've got left. Maybe "disk free" doesn't apply quite as well to du's function.
If I was designing them from scratch, I'd maybe call them something like "size" and "space" respectively.
I learned Unix in the mid 80s but it wasn't until sometime later I learned or had the epiphany that grep was shorthand for g/re/p. As in global search for regular expression and print the results. Talk about a forehead slapping moment. Not everything in Unix is immediately obvious.
I always end up using both du and df because I can never remember which does what. Half the time, I also can’t remember their names even and have to look them up.
All of the really frequent commands, I can remember (cp, mv, cat, tar, head, tail, ls, mkdir, rm, grep, sed, and a handful of common programs like package managers and git) and everything else I can never remember and have to look up. I personally don’t like the unix command names, most don’t make much sense to me personally. Sure, I like that they’re short, but I can never remember them unless I use them a lot.
Tab completion to the rescue! Once you're a few letters past the dash in Powershell, you can just hot the tab key until you've cycled through the few commands it spells. Same for parameters.
Doesn't help that a lot of commands have the same prefix 'Get-' / 'Set-', 'Add-', etc, so you have to type at least 6 characters, including a '-', to get useful completion.
Powershell has aliases, so you can use 'ls' instead of 'Get-ChildItem'. My colleagues tend to use Get-ChildItem in scripts and ls when typing at the command prompt.
Personally, I prefer 'ls' for scripts too. I would never use "rd" for a variable name, but since I speak Unix, the more concise 'ls' seems better. To my colleagues without a Unix background, Get-ChildItem, probably is a better choice.
These are the approved verbs. Powershell function names have to be in "verb-noun" format, forcing a level of standardization on the language. It seems like an odd idea to me.
I thought it came from JCL's DD (Data Definition) statement. Even the parameter syntax is somewhat reminiscent of JCL's DD, while being completely alien to normal Unix commands.
The dd-style syntax isn't actually that bad. of=X if=Y is possibly easier to remember than -o X -i Y, while still being less typing that --output X --input Y.
JCL itself has a lot of warts, no denying that. But the basic idea behind the DD statement is interesting. In Unix, file descriptors are just numbers; whereas, in classic MVS, instead of numeric file descriptors the API uses 1-8 character names (DDNAMEs). While in principle a Unix program can inherit any number of file descriptors, in practice very few programs inherit any more than 0-2, because remembering numbers has poor usability. In classic MVS, it is not uncommon for a program to inherit more than 3 file descriptors, because they are assigned names not numbers. ("File descriptors" and "inherit" are not quite the right terms, but trying to use Unix-like language to make it comprehensible to people.)
(And I say classic MVS, because contemporary z/OS is actually a conforming Unix implementation so it supports numeric file descriptors in the Unix API, as well as alphanumeric DDNAMEs in the classic MVS API.)
My favorite, related, piece of trivia about JCL is the IEFBR14 program: the no-op program that took a few attempts to get it right :-) [1]. Its entire purpose was motivated by JCL not having primary commands to do file management, which is only allowed as a "side effect" of executing a program
I'm not sure it is fair to call that a wart. Back when JCL was designed, C/C++ didn't exist yet, and nobody used "//" as a comment syntax. (C's predecessor BCPL introduced // comments, but it was designed in 1967, and OS/360 was already shipping to customers in 1966; C itself was designed in 1972, and initially it didn't have // comments; C++ borrowed them from BCPL in the 1980s, and then C borrowed them back from C++ after that.)
A more obvious example of a wart would be how it exposes low-level details of disk layout (e.g. space allocation in cylinders and tracks), which improved performance and simplified implementation back in the 1960s, but which nowadays is just useless complexity–modern disks have completely different physical layout, and you have to buy expensive mainframe-specific SAN controllers which know how to simulate the ECKD physical layout of legacy mainframe disks on top of modern industry standard disks/SSDs.
I'm pretty sure that was coined specifically in reference to the Deskstar 75GXP series, not Deskstar drives in general. The Deskstar brand name is actually still used by HGST for its NAS drives, which seem to be reasonably well-regarded for their intended applications.
The reason is that scp was designed as a secure replacement for rcp, which was designed as a remote version of cp. The flags -p and -r were inherited from cp by rcp (see https://linux.die.net/man/1/rcp), so for compatibility scp had to use the same flags.
As for ssh, I haven't looked at its history, but I suspect it's older than scp; the intuitive flag for "port" is -p, so that's what ssh used.
I've been using a similar command called 'cheat' [pip install cheat] which does more or less the same thing. I wonder which of the two is more comprehensive. How would I check this efficiently?
troff -m specifies which macro package to use and the system docs are written with the "an" macro set. So you can runoff (pun intended) the manpages using troff -man.
I once asked Gumby if he and John Gilmore and Michael Tiemann named their company "Cygnus" as the result of typing "grep gnu /usr/dict/words". Without missing a beat, he replied that if they'd thought of doing that, they would have named the company "Wingnut".
Googling the difference (hint: none) I found this lovely ditty:
I never concatenate strings;
I just catenate those little things.
Of syllables few,
I'm a man through and through.
Shorter words? My heart joyfully sings!
Fair enough, but more also made sense to me because I assumed (apparently rightly) that its name refers to the "-- More --" prompt at the end of each screenful.
In math and physics there is the Pin group which is named because it relates to the Spin group (named after spin like of an electron) in the same way that SO (special orthogonal group) relates to O (orthogonal group) and SL (special linear group) relates to GL (general linear group). This is something some mathematicians find quite amusing.
Edit: also some say rng which is a ring without an identity (without an i). I think there are others similar to this.
EMACS may stand for "Editing MACroS," but some friends of mine suggested some more creative definitions.
Here they are. Anyone have any additions?
Eight Megabytes And Constantly Swapping
Even a Master of Arts Comes Simpler
...
I'm often surprised how Emacs can struggle sometimes on modern hardware, like for example when chain-executing complex keyboard macros - though mostly yeah, it doesn't apply all that much anymore.
The issue is it remains non-concurrent and any code (macros, extensions, …) executes in place of the editor doing its thang, so any non-trivial operation (or trivial operation on an entire buffer) locks up the editor until it's done and does its thing.
And while it might technically be faster for the process, as is the case with e.g. STW GCs on large processes it 1. feels horrible and 2. as an editor is interactive it stops the user in their tracks and slows them down to hell
As I recall, it used to be officially called Yellow Pages in SunOS, but there was a dispute with British Telecom which owned the trademark on Yellow Pages, so Sun changed its name.
> Because British Telecom PLC owned the name "Yellow Pages" as a registered trademark in the United Kingdom for its paper-based, commercial telephone directory, Sun changed the name of its system to NIS, though all the commands and functions still start with "yp".
I always thought Yellow Pages was a generic term, but that's only in the USA. In other countries it's a trademark and owned by specific countries. TIL.
I understood that it originally stood for "yellow pages" because it is a directory service, but that the phone company asserted their trademark on the term.
In case you're asking about the older product, yes I still get a phone book on my porch every 6 months to a year with updated residential and business phone numbers, including ads for the businesses.
UK: yes, we still get sent one (along with a residential directory). It's no longer phone directory sized though. Now midway between A4 and A5 sized and about a centimeter thick.
Also in the UK.
The last Yellow Pages we received, about two months ago, had a large ‘Final Issue‘ highlight on the front. They’ve finally given up.
I tried to dredge up some nostalgic feelings for it’s demise, but flicking through the contents I really couldn’t. About 40% of the ad space throughout the book was for one advertiser, Gas Safe Register, and I can only assume that got sold at a song to fill the space.
I’d love to know the percentage of the population that are going to miss it. I can see why it’s no longer effective with search engines being what they are, but there must still be a decent number of (presumably older) people who don’t google when they need contact details.
Sort of. UDDI had sought to replace yellow pages (and other colors) in the Java/SOA world of the mid 2000s. LDAP (successor to yp/nis) lost the page terminology on the way to standardization.
I am French, I know about "système D" but I never associated it with systemd.
"Système D" implies making use of what's available, it is hacking (the good kind). systemd is the opposite, it is nothing like a quick and dirty solution to a problem but a major architecture change that intends to replace these hacks with something cleaner.
If the french expression really was the origin of the "systemd" name, it has to be in a twisted kind of way, or some kind of private joke. It would be like calling an electric car "octane" or something like that.
Nor should you have. The systemd people themselves have been pointing out for years that it is "something completely different" and not the origin, let alone the correct spelling, of the name.
systemd is pretty much the exact opposite of that philosophy. Quick and dirty would be an init system that simply executed script files in a directory in asciibetical order and then bolts on a configuration language in the comments of those scritps when they become too hard to manage manually. And then extending that configuration language with X-* options when you need to add new keys but can't be sure a existing software doesn't already use those names differently.
Equally the history of why we have /bin /sbin and /usr/bin. Lack of disk space. When the OS got too big for a single disk and expanded to a second the split came about. /home came about when they expanded to a third!
Also, remember that the /usr used to mean "user", as in, if you were "bob" then your home directory was /usr/bob. That dance was done twice!
Moving stuff to /usr/bin made sense after systems got too big for a single volume and you've got this directory on a nice, new spacious multi-megabyte disk (oooh!) In those ancient days of Unix the sysop acting as the "bin" user owned /bin and the files inside it and could overwrite them from tapes or compilation.
(root would own the files in the sbin)
So /usr/bin technically started out as his or her home directory when logging in as that account... at least back then.
/usr/sbin only came about after /home became the colloquial location for home directories, such that you had parallel constructions for /bin and /sbin under /usr, and later, /usr/local just as you did at the root.
bc = Belinda's Calculator. Apparently named after Belinda Cherry. [1]; i don't know who that is, but i assume she needed to do arithmetic on a unix machine a long time ago.
There's an older unix calculator called dc, for desk calculator; dc uses reverse-Polish, so it's a pain to use if you didn't grow up using those weird old HP calculators (or writing Forth). My understanding is that bc began as a shell script which would translate infix expressions into RPN and pass them to dc.
These days, if i want to do sums, i fire up a Python interpreter, or just plug them into a Google search box or Firefox address bar. But back in the day, i would use bc.
Yes, bc is useful. You can even pipe standard input into bc, and get the results of the calculations on standard output.
bc -l
used to be the invocation I used a lot.
I do that Google thing myself nowadays too :) They can even give answers to factorial(n) and the like. Found that recently. Wouldn't be surprised if a lot more too.
They were sent over a network. Every baud counts. And then the output had to have a fixed width (not necessarily a fixed length, since it may have been printed on paper) because of "display" size.
There used to be a type where 80x24 character terminals were a luxury, and even a type where printing commands and ouput actually meant printing on paper. Unix was developped in these times.
If Perl programs (executables, whatever you call them) are called "modules", why is the main place people download them from called CPAN?
It's completely illogical.
C = Comprehensive (It's not, it definitely does not contain all possible modules)
P = Perl (This is only one that makes sense)
A = Archive (If the things people create are called modules - .pm files, really - what makes this an archive? A collection of things? That's a weak leg to stand on. Yes, distributions formalizes this, but modules seems to be the common nomenclature.
N = Network (How is this a network? I think Wall - or later, Hietaniemi - just wanted people to think it was big and important in the early days)
This is all absurd and slightly sarcastic, but I finally got to write it down somewhere :)
CPAN was named after (in imitation of) CTAN, the Comprehensive TeX Archive Network. CTAN was named by George Greenwade — the idea was to bring together (network) various TeX archives that various people had collected. See:
There are multiple CPAN sites, which rsync from each other in a hierarchical way, so "network" is quite appropriate. And they retain all previous versions, so they're an archive. Also, the intention was for it to contain all published modules, and it has indeed grown to be, I think, the largest repository of modules for any language. Comprehensive does not mean complete.
The archive is the collection of archive files which contains a combination of software libraries, documentation, programs, tests, and metadata. It also includes manifests, checksums and other data useful for the CPAN program.
The network is a collection of 250+ mirrors of the archives.
Ok, I'll grant you "all" is in the defintion, but so is "nearly all". Comprehensive is often used with a modifier to denote that it doesn't cover all possibilities. It also is applied to subjects that can't include all possibilities, or where they can't reasonably be known. Its root word compréhensif also hints at the subject covering many areas, but not all of them; a thorough understanding.
CPAN covers nearly all Perl libraries, and also covers nearly all categories of modules, as they are organized into a hierarchy based on topic, and the modules' naming naturally falls into a hierarchy as well. It's easy to find a module even without a search engine, and thus easy to find out whether you need to make one or whether one already exists. The result is a comprehensive archive of libraries.
> You might say that Perl grew out of the Cold War. I’ve often told the story about how Perl was invented at a secret lab that was working on a secret NSA project, so I won’t repeat that here, since it’s no secret. Some of you have heard the part about my looking for a good name for Perl, and scanning through /usr/dict/words for every three- and four-letter word with positive connotations. Though offhand, I can’t explain how I missed seeing Ruby. So anyway, I ended up with “Pearl” instead.
> “Perl” is usually glossed as “Practical Extraction and Report Language,” and occasionally as “Pathetically Eclectic Rubbish Lister.” Both are retronyms. Originally, Larry wanted to name his new language Pearl, a word with positive connotations. Larry considers himself as much a linguist as a hacker. He’s also a fan of Tolkien’s Lord of the Rings. There are doorways into Tolkien’s imagination built right into the core of Perl. Each section of the source code begins with a quote from the Rings trilogy – say, “A fair jaw-cracker dwarf language must be.” If you understand the epigram, you comprehend what that section is designed to do. Larry wanted to give Perl a name that suggested that it was worth treasuring.
> Furthermore, Larry is a devout Christian – he’s the son of a fundamentalist Mennonite preacher from a long line of preachers. In the 13th book of Matthew, Jesus tells the parable of a merchant “seeking goodly pearls, who, when he had found one pearl of great price, went and sold all that he had, and bought it” – “it” being the Kingdom of Heaven. But there was already another programming language called Pearl. So Larry – whose personal motto, which has become the mantra of the Perl community, is “There’s more than one way to do it” – christened his new creation Perl.
I read somewhere that "Perl" isn't actually any kind of acronym but really stands for a pearl (the glossy ball thingy produced by certain species of sea life) - the reason being some kind of biblical reference to it.
"Historically, program output was printed on paper rather than on screens. So the print part is due to the output technology of the time that the command was developed."
>> The Perl language is Larry Wall's highly popular
freely-available completely portable text, process, and file
manipulation tool that bridges the gap between shell and C
programming (or between doing it on the command line and
pulling your hair out).
That's ...an interesting definition of Perl. Last I heard it was the "gaffer tape of the internet" or some such. I put off learning Perl for so long that I don't need to anymore. I wonder how often it's used nowadays.
No, that's not the origin of the name. Someone thought that up later. Also, the regex is globally matched, after having been parsed just once, so the name would not even make sense.
One day, Laurie S. from the business side came over to ask me for some help with her system: "I think I've filled up my disk, but how can I find out?" "Well, the 'df' command will show you that info." "But," she replied, "won't that just show me the files in your home directory?" "My home directory??? Why would it do that?" "Well, my initials are LS and that shows my files, and DF are your initials, so that should show your files."
I was super impressed.