A="a.txt b.txt" echo "" echo "loop string" for j in $A; do for i in `find . -maxdepth 1 -iname $j`; do echo $i mv $i newfolder/$i done done
Use .sh file can be run, ignore file name case
This method also can ignore file name case, look for whether a file exists