I want to move files from one folder to another folder, my code is working fine when file name doesn't contain spaces but if there is a space in a file name then I am getting an error My Code is as follows :
find [folderName] -size +1k -type f -name \*.txt -print0 | while IFS= read -r -d '' file; do
echo $file
mv $file targetfolderName
done
File Names
sample 01.txt test - copy 01.txt