Created
March 23, 2017 17:11
-
-
Save polaroi8d/7cb49d388a5bb054d05c878f9aa327a6 to your computer and use it in GitHub Desktop.
If you want to rename a lots of variable, use this script instead of CTRL + H 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
#!/bin/bash | |
FROM=$1 | |
TO=$2 | |
DIR=$PWD | |
FILES=`ls -1 "$DIR"` | |
for file in "$FILES" | |
do | |
sed -i -e "s/${1}/${2}/g" ${file} | |
echo "in ${file} ${FROM} renamed to ${TO}" | |
done |
TODO:
- #endif *!
- add missing tests ( delete dump )
- automatic roll on HTML client
- automated js files input (hz?)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
git ls-files --modified | xargs git add