Skip to content

Instantly share code, notes, and snippets.

@bisignam
Last active May 26, 2021 12:06
Show Gist options
  • Save bisignam/5f6fb1ca0ce502b9d857313a14c84b10 to your computer and use it in GitHub Desktop.
Save bisignam/5f6fb1ca0ce502b9d857313a14c84b10 to your computer and use it in GitHub Desktop.
Delete files older than a given date in the current directory (depth 1)
find . -maxdepth 1 -type f '!' -newermt '2020-12-31' -print0 | xargs -0 rm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment