Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- # add .full to the end of any file, right before the file extension. This is useful for renaming a folder full a MTG pictures, so they are prepared for Magic Workstation.
- SFILES="*.jpg"
- for f in ${SFILES}
- do
- mSuffix=$(echo $f | awk 'BEGIN { FS = "." } ; {print $1}')
- mNewFName="$mSuffix"".full.""jpg"
- echo $mNewFName
- #empty space before the ext of the file is cleared
- #mNewFName=$(echo ${mNewFName} | sed 's/ .bg.'$mSuffix'/'.bg.$mSuffix'/g')
- mv "${f}" "${mNewFName}"
- #ShowNumber=$((ShowNumber+1))
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement