Created
September 8, 2015 18:26
-
-
Save tracertea/1b7e6c563c9553e8f595 to your computer and use it in GitHub Desktop.
Run batch multi parameter commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cat myFile.txt | xargs -I {} sh -c 'p=(`echo $0`); echo ${p[1]} ${p[0]}' {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cat myFile.txt | xargs -n1 | while read f; read g; do echo $f $g; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment