Skip to content

Instantly share code, notes, and snippets.

@mfontani
Created November 8, 2010 19:34
Show Gist options
  • Save mfontani/668141 to your computer and use it in GitHub Desktop.
Save mfontani/668141 to your computer and use it in GitHub Desktop.
Repack all my Git repos, si vous plait!
#!/bin/sh
# Marco Fontani - MFONTANI at cpan dot org
# Repack all the .git repos from the current directory
# using 8 processes at once
find . -type d -name '.git' | \
xargs -I{} -P8 \
sh -c "(cd {}/..; git gc; echo done {})2>/dev/null"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment