Ticket #51158: git-gc-all-ferocious

File git-gc-all-ferocious, 312 bytes (added by RJVB (René Bertin), 8 years ago)
Line 
1#!/bin/sh
2
3(
4        cd .git
5        rm -rf refs/remotes/ refs/original/ *_HEAD logs/
6)
7
8git for-each-ref --format="%(refname)" refs/original/ | xargs -n1 --no-run-if-empty git update-ref -d
9git -c gc.reflogExpire=0 -c gc.reflogExpireUnreachable=0 -c gc.rerereresolved=0 -c gc.rerereunresolved=0 -c gc.pruneExpire=now gc "$@"