I'm trying to move several .avi files that have spaces in from a CD to my home folder. I've already know how to get rid of the spaces:
find /media/mathscd/ | grep -L -r "*.avi" | for file in *; do mv "$file" echo $file | tr ' ' '_' ; done
But I'm struggling to get move to find the edited files and move them en masse into the folder. I keep getting the error mv: cannot stat '(standard input)': No such file or directory. This is the code I'm trying to use:
find /media/mathscd/ | grep -L -r "*.avi" | xargs -I{} mv {} /home/09murphyt/Downloads/
Can someone please tell me what I'm doing wrong?
greptrying to match?{}in quotes, i.e. mv"{}".