Created
November 28, 2018 01:37
-
-
Save aikar/dcc2704851ada2122e0631a0f84e1783 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 | |
pwd=`pwd` | |
for dir in $(find . -type d -name ".git" | sed 's/\/.git//g'); do | |
cd "$pwd/$dir" | |
git reflog expire --expire-unreachable=3d | |
git gc --prune=5d | |
git gc --aggressive | |
git prune | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment