Skip to content

Instantly share code, notes, and snippets.

@jo-tilkee
Last active April 18, 2017 15:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jo-tilkee/e052da8f252e976e12e4c2960cc402d8 to your computer and use it in GitHub Desktop.
Save jo-tilkee/e052da8f252e976e12e4c2960cc402d8 to your computer and use it in GitHub Desktop.
[manipulation de fichiers]: Changer toutes les extensions d'un type en un autre
#!bash
old_extension="sql"
new_extension="back"
for i in `ls *.$old_extension`
do
file=`basename $i .$old_extension`
mv $i $file.$new_extension
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment