Created
October 7, 2015 03:08
-
-
Save chernjie/76bebbf6e0e5239266ba to your computer and use it in GitHub Desktop.
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
#!/usr/bin/env bash | |
variable_name="$1" | |
shift | |
while read "$variable_name" | |
do | |
eval "$(echo "$@" | sed s/"$variable_name"/'"'\$"$variable_name"'"'/g)" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
$ cat filelist.txt | whileread _line wc -l _line