I'm trying to figure out a command to move or delete duplicate files from a directory using 'fdupes' and 'xargs'. Here's what I have so far
The problem with this command is that it can't handle file names with spaces in them. Reading xargs's man page there's a --delimiter option which is supposed to accepet /n but when I use it it still splits the file name:
fdupes -f . | xargs mv -t ~/duplicates
xargs also has -0 option with works with null sperators but fdupes only used \n as a seperator.
fdupes -f . | xargs --delimiter=\n mv -t ~/duplicates
Any ideas on how to do this?