Difference between revisions of "Xargs"

From Useful Things
Jump to: navigation, search
(Created page with "== Build argument list from previous output == <pre> command | xargs ls -l </pre> == Run command per line of previous output == <pre> command | xargs -L1 ls -l </pre> == Run...")
 
(No difference)

Latest revision as of 16:05, 24 June 2015

Build argument list from previous output

command | xargs ls -l

Run command per line of previous output

command | xargs -L1 ls -l

Run piped command per line of previous output

command | xargs -L1 sh -c 'command2 "$0" | command3'