Created
April 13, 2012 11:38
-
-
Save HansCz/2376143 to your computer and use it in GitHub Desktop.
Bash - read two files and insert their lines in a bash command
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
# read two files and insert their lines in a bash command | |
# http://www.linuxquestions.org/questions/programming-9/help-with-bash-script-rename-multiple-files-347062/ | |
# | |
# usage example: | |
# | |
# $ do2lists filelist_originalnames.txt filelist_newnames.txt | bash | |
ARGV[1] == FILENAME{ | |
getline out2 < ARGV[2] | |
print "mv \"" $0 "\" \"" out2 "\"" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment