Created
December 5, 2019 08:28
-
-
Save Scarbous/4405806d0bace7efc5c2b10a4eba71bc to your computer and use it in GitHub Desktop.
Bash Commands
This file contains 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
# get files bigger then 1G in current dir | |
find . -maxdepth 5 -type f -size +1G -print0 | xargs -0 ls -Shal | |
# get size of folders in current dir, sortet by size | |
du -h -d1 | sort -h | |
# delete files older then 7 days in current dir | |
find . -type f -mtime +7 -print | xargs rm | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment