Skip to content

Instantly share code, notes, and snippets.

@Strykar
Created September 1, 2016 12:28
Show Gist options
  • Save Strykar/609792c8b9b7da47eae1553ba5429922 to your computer and use it in GitHub Desktop.
Save Strykar/609792c8b9b7da47eae1553ba5429922 to your computer and use it in GitHub Desktop.
# Script to delete files older than one hour - run from cron
# Wednesday, November 07, 2007
#!/bin/bash
find /path/to/dir -cmin +60 -type f -maxdepth 1 -exec rm {} \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment