Skip to content

Instantly share code, notes, and snippets.

@davsclaus
Created February 23, 2017 09:09
Show Gist options
  • Save davsclaus/fa2e7c73a8a697c63dde63ca0d8be59a to your computer and use it in GitHub Desktop.
Save davsclaus/fa2e7c73a8a697c63dde63ca0d8be59a to your computer and use it in GitHub Desktop.
#!/bin/sh
M2_REPO=${HOME}/.m2
OLDFILES=/tmp/oldfiles.txt
find "${M2_REPO}" -type f -name '*SNAPSHOT*' -exec dirname {} \; >> ${OLDFILES}
for x in `cat ${OLDFILES}`; do rm -rf "$x"; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment