Skip to content

Instantly share code, notes, and snippets.

@maiquelleonel
Created June 13, 2015 12:59
Show Gist options
  • Select an option

  • Save maiquelleonel/c8aa9cda60158da71c7d to your computer and use it in GitHub Desktop.

Select an option

Save maiquelleonel/c8aa9cda60158da71c7d to your computer and use it in GitHub Desktop.
#!/bin/bash
pwd=$(pwd)
cd app/imgs
for file in $(ls ./); do
name=(${file//_/ })
mv $file ${name[1]}"_"${name[2]}
done
cd $pwd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment