Re: xargs with max each line / argument

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Tue, May 17, 2011 at 12:36:08AM -0500, neubyr wrote:
> How do I pass xargs input one line at a time to subsequent command?

xargs is the wrong tool for this job.

> $ awk '{ print $0 }' gem.list.1 | xargs -L 1 -0 -I name sudo gem install name

while read line
do
  sudo gem install $line
done < gem.list.1

-- 

rgds
Stephen
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux