home *** CD-ROM | disk | FTP | other *** search
/ Aminet 4 / Aminet 4 - November 1994.iso / aminet / dev / gcc / gcc260utilsdoc.lha / gnu / man / man1 / xargs.1 < prev    next >
Encoding:
Text File  |  1994-07-31  |  5.1 KB  |  133 lines

  1.  
  2.  
  3.  
  4. XARGS(1L)         MISC. REFERENCE MANUAL PAGES          XARGS(1L)
  5.  
  6.  
  7.  
  8. NAME
  9.      xargs - build and execute command lines from standard input
  10.  
  11. SYNOPSIS
  12.      xargs  [-0prtx]  [-e[eof-str]]  [-i[replace-str]]   [-l[max-
  13.      lines]] [-n max-args] [-s max-chars] [-P max-procs] [--null]
  14.      [--eof[=eof-str]]     [--replace[=replace-str]]      [--max-
  15.      lines[=max-lines]]  [--interactive]  [--max-chars=max-chars]
  16.      [--verbose]   [--exit]    [--max-procs=max-procs]    [--max-
  17.      args=max-args]    [--no-run-if-empty]   [command   [initial-
  18.      arguments]]
  19.  
  20. DESCRIPTION
  21.      This manual page documents the GNU version of xargs.   xargs
  22.      reads arguments from the standard input, delimited by blanks
  23.      (which can be protected with double or single  quotes  or  a
  24.      backslash) or newlines, and executes the _c_o_m_m_a_n_d (default is
  25.      /bin/echo) one or more times with any _i_n_i_t_i_a_l-_a_r_g_u_m_e_n_t_s fol-
  26.      lowed by arguments read from standard input.  Blank lines on
  27.      the standard input are ignored.
  28.  
  29.      xargs exits with the following status:
  30.      0 if it succeeds
  31.      123 if any invocation of the command exited with status 1-125
  32.      124 if the command exited with status 255
  33.      125 if the command is killed by a signal
  34.      126 if the command cannot be run
  35.      127 if the command is not found
  36.      1 if some other error occurred.
  37.  
  38.   OPTIONS
  39.      --_n_u_l_l, -_0
  40.           Input filenames are  terminated  by  a  null  character
  41.           instead  of by whitespace, and the quotes and backslash
  42.           are not special (every character is  taken  literally).
  43.           However,  any  end  of file string is still recognized.
  44.           Useful with the GNU find -print0 option when  filenames
  45.           might contain white space, quote marks, or backslashes.
  46.  
  47.      --_e_o_f[=_e_o_f-_s_t_r], -_e[_e_o_f-_s_t_r]
  48.           Set the end of file string to _e_o_f-_s_t_r.  If the  end  of
  49.           file  string occurs as a line of input, the rest of the
  50.           input is ignored.  If _e_o_f-_s_t_r is omitted, there  is  no
  51.           end  of  file string.  If this option is not given, the
  52.           end of file string defaults to "_".
  53.  
  54.      --_r_e_p_l_a_c_e[=_r_e_p_l_a_c_e-_s_t_r], -_i[_r_e_p_l_a_c_e-_s_t_r]
  55.           Replace occurences of _r_e_p_l_a_c_e-_s_t_r in the initial  argu-
  56.           ments   with   names  read  from  standard  input.   If
  57.           _r_e_p_l_a_c_e-_s_t_r is omitted, it defaults to "{}"  (like  for
  58.           `find -exec').  Implies -_x and -_l _1.
  59.  
  60.  
  61.  
  62.  
  63. Sun Release 4.1           Last change:                          1
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. XARGS(1L)         MISC. REFERENCE MANUAL PAGES          XARGS(1L)
  71.  
  72.  
  73.  
  74.      --_m_a_x-_l_i_n_e_s[=_m_a_x-_l_i_n_e_s], -_l[_m_a_x-_l_i_n_e_s]
  75.           Use at most _m_a_x-_l_i_n_e_s nonblank input lines per  command
  76.           line;  _m_a_x-_l_i_n_e_s  defaults  to  1 if omitted.  Trailing
  77.           blanks cause an input line to be logically continued on
  78.           the next input line.  Implies -_x.
  79.  
  80.      --_m_a_x-_a_r_g_s=_m_a_x-_a_r_g_s, -_n _m_a_x-_a_r_g_s
  81.           Use at most _m_a_x-_a_r_g_s arguments per command line.  Fewer
  82.           than  _m_a_x-_a_r_g_s  arguments will be used if the size (see
  83.           the -s option) is exceeded, unless  the  -x  option  is
  84.           given, in which case xargs will exit.
  85.  
  86.      --_i_n_t_e_r_a_c_t_i_v_e, -_p
  87.           Prompt the user about whether to run each command  line
  88.           and  read  a line from the terminal.  Only run the com-
  89.           mand line if the  response  starts  with  `y'  or  `Y'.
  90.           Implies -_t.
  91.  
  92.      --_n_o-_r_u_n-_i_f-_e_m_p_t_y, -_r
  93.           If the standard input does not contain  any  nonblanks,
  94.           do  not  run the command.  Normally, the command is run
  95.           once even if there is no input.
  96.  
  97.      --_m_a_x-_c_h_a_r_s=_m_a_x-_c_h_a_r_s, -_s _m_a_x-_c_h_a_r_s
  98.           Use at most  _m_a_x-_c_h_a_r_s  characters  per  command  line,
  99.           including  the  command  and  initial  arguments.   The
  100.           default is as large as possible, up to 20k characters.
  101.  
  102.      --_v_e_r_b_o_s_e, -_t
  103.           Print the command line on  the  standard  error  output
  104.           before executing it.
  105.  
  106.      --_e_x_i_t, -_x
  107.           Exit if the size (see the -_s option) is exceeded.
  108.  
  109.      --_m_a_x-_p_r_o_c_s=_m_a_x-_p_r_o_c_s, -_P _m_a_x-_p_r_o_c_s
  110.           Run up to _m_a_x-_p_r_o_c_s processes at a time; the default is
  111.           1.  If _m_a_x-_p_r_o_c_s is 0, xargs will run as many processes
  112.           as possible at a time.  Use the -_n option with -_P; oth-
  113.           erwise chances are that only one exec will be done.
  114.  
  115.      The long-named options can be introduced with `+' as well as
  116.      `--',  for compatibility with previous releases.  Eventually
  117.      support for `+' will be removed, because it is  incompatible
  118.      with the POSIX.2 standard.
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129. Sun Release 4.1           Last change:                          2
  130.  
  131.  
  132.  
  133.