3

The common unix utility program grep is an abbreviation of "globally search a regular expression and print", which makes grep a case of "does what it says on the tin". The name informs us of the functionality of the program.

Is there a similar history behind the name of 'xargs'? Does the name have any meaning that helps as mnemonic in the same way as grep does?

5
  • 1
    I have no source for it, but I had assumed that "x" represented the multiplication or "times" symbol, and "args" was "arguments".
    – JigglyNaga
    Commented May 23, 2019 at 9:10
  • 4
    Best reference found: "The name xargs, pronounced EX-args, means “combine arguments.”" From the Overview in GNU findutils manual.
    – fra-san
    Commented May 23, 2019 at 10:21
  • A better reference to consult is the SVID.
    – JdeBP
    Commented May 23, 2019 at 12:16
  • 1
    The man index in pwb1 unix says "xargs(I): construct argument list(s) and execute command", so it looks like it's "execute-args". But there's no indication that its authors haven't use the x just for euphony ;-)
    – user313992
    Commented May 23, 2019 at 14:24
  • 1
    A better venue for such questions would be the tuhs mailing list, where you may obtain such info directly from the people who invented it.
    – user313992
    Commented May 23, 2019 at 14:37

3 Answers 3

6

The description in the Unix System 5 administrator's reference manual, the X/Open Portability Guide, and the System V Interface Definition is:

xargs — construct argument list(s) and execute command

These pre-date by years Wolfram Roesler's 1993 Unix Acronym List which calls it "extended arguments". As does Gordon A. Moffet's xargs clone published in 1986 whose manual says:

xargs — execute a command with many arguments

However: Whilst the System 5 doco and the clone doco might lead one to conclude that yes "x" relates to "execute", "extend" per Wolfram Roesler's Unix Acronym List is in fact more likely the case. Herb Gellis's own commentary on the subject implies that xe wrote it to extend the then limit of 512 bytes on filename expansion in the Mashey shell.

Herb Gellis is apparently still alive. You could ask xem. ☺

2

Xargs means: eXtended ARGumentS.

4
  • 1
    Do you have a source for this claim? Like Max M's answer, this sounds plausible, but it would be nice to know if this is mentioned in some manual or other official description of xargs. Commented May 23, 2019 at 13:42
  • Not now, or: not from an Unix manual. If I find something .....
    – user232326
    Commented May 23, 2019 at 13:50
  • This may be of help: roesler-ac.de/wolfram/acro/Cmd.htm
    – user232326
    Commented May 23, 2019 at 14:01
  • An old book reference: netzmafia.de/skripten/unix/unix11.html
    – user232326
    Commented May 23, 2019 at 14:15
1

xargs means "execute arguments". Some commands can not take input straight from the standard input but only as arguments (e.g. echo, rm). xargs converts data from the standard input into executable arguments and tells the following command to execute those arguments.

7

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .