Last active
May 17, 2020 04:29
-
-
Save felixmon/27ee5d3afa6a628ae5292e3528edda6b to your computer and use it in GitHub Desktop.
remove / delete files with size range
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # remove files less then 100k | |
| find . -type 'f' -size -100k -delete | |
| # remove tif files less than 160k | |
| find . -name "*.tif" -type 'f' -size -160k -delete | |
| # remove files that do NOT match with the pattern | |
| find . -type f ! -name '*.txt' -delete |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment