Find and delete when found

On the terminal, if you want to delete a lot of items at once without dragging them to the trashcan icon, type:

find [source path] -name "*[whatever word you want to find]*" -delete

Beware this is not the same as dragging to the trash, it's permanent and non-recoverable. I'd suggest running this first to make sure it will delete the right things:

find [source path] -name "*[whatever word you want to find]*" -print


Popular posts from this blog

ZFS syntax (updated)

/var/log/journal taking up lots of space

throttle traffic on apache