Lets say I have them 001, 002, 003 .. etc.. How can I rename them 200,201,202 or just do 1-001, 1-002, 1-003
Anyone knows a command or script?
Anyone knows a command or script?
#!/bin/bash
i=1;
shopt -s nullglob;
for f in *.{jpg,jpeg,JPG,JPEG,gif,GIF,png,PNG}; do
ext="${f##*.}";
ext=${ext,,};
ext=${ext/jpeg/jpg};
mv -- "$f" "newfolder/$i.${ext}";
((i++));
done


Comment