Last Updated: February 25, 2016
·
403
· novalagung

Bash - Delete files by Size

We can delete all files in specific folder by using these commands :

sudo find /path/fo/folder/ -type f -size -100k -exec rm {} +

just for information about value of -size :

  • -100k means all files that have size below 100kb
  • +50M means all files that have size above 50Mb