Xargs

xargs
Developer(s)Various open-source and commercial developers
Operating systemUnix, Unix-like, Plan 9, IBM i
PlatformCross-platform
TypeCommand

xargs (short for "extended arguments")[1] is a command on Unix and most Unix-like operating systems used to build and execute commands from standard input. It converts input from standard input into arguments to a command.

Some commands such as grep and awk can take input either as command-line arguments or from the standard input. However, others such as cp and echo can only take input as arguments, which is why xargs is necessary.

A port of an older version of GNU xargs is available for Microsoft Windows as part of the UnxUtils collection of native Win32 ports of common GNU Unix-like utilities.[2] A ground-up rewrite named wargs is part of the open-source TextTools[3] project. The xargs command has also been ported to the IBM i operating system.[4]

  1. ^ "The Unix Acronym List: The Complete List". www.roesler-ac.de. Retrieved 2020-04-12.
  2. ^ "Native Win32 ports of some GNU utilities". unxutils.sourceforge.net.
  3. ^ "Text processing tools for Windows".
  4. ^ IBM. "IBM System i Version 7.2 Programming Qshell" (PDF). Retrieved 2020-09-05.