Created
February 1, 2017 18:46
-
-
Save matthiasbalke/d8d3ff706c3d9ec787fb481925719f04 to your computer and use it in GitHub Desktop.
delete a selected artifact / group from gradle local cache
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 | |
deleteGradleCache() { | |
local id=$1 | |
if [ -z "$id" ]; then | |
echo "Please provide an group or artifact id to delete" | |
return 1 | |
fi | |
find ~/.gradle/caches/ -type d -name "$id" -prune -exec rm -rf "{}" \; -print | |
} | |
deleteGradleCache $1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment