Change File Extensions

Changes all file extensions matching the old extension to the new extension in a directory

Simply fill in the parameters and run the ".sh" script

OLD_FILE_EXT=".PNG"
NEW_FILE_EXT=".png"
DIR="/home/user/NAS/RomProject/temp/art/"

IN_FILES="$DIR*$OLD_FILE_EXT"

for f in $IN_FILES
do
  base_name=$(basename "$f" $OLD_FILE_EXT)
  mv "$f" "$DIR$base_name$NEW_FILE_EXT"

  echo "Processing: $f"

done
My Keybase Page: https://keybase.io/benjamichaelson Follow Me!