Last active
March 7, 2025 06:41
-
-
Save itspacchu/e473dc08ecc8809f52986973d0742407 to your computer and use it in GitHub Desktop.
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
#!/bin/bash | |
echo "Deleting files older than 5 days" | |
files=$(find ./ -mtime +5) | |
for file in $files; do | |
echo "- Deleted $file" | |
rm -rf $file | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment