Using find and xargs

Deleting

find /path -type f -print0 | xargs -0 rm

Moving

find /path -name "*.foo" -print0 | xargs -0 -I xxx mv xxx /var/tmp

Probably a good idea to test your command first:

find /path -name "*.foo"

Delete all .svn directories

find . -type d -name '.svn' -print0 | xargs -0 rm -rf


CategoryLinux CategorySubversion

FindXargs (last edited 2009-12-02 12:16:58 by DavidKeen)