git-repack
Pack loose objects into pack files
TLDR
Repack objects
$ git repack
Repack aggressively$ git repack -a -d
Repack with delta compression$ git repack -a -d --depth=[250] --window=[250]
Repack all objects$ git repack -A -d
Repack with geometry$ git repack --geometric=[2]
SYNOPSIS
git repack [options]
DESCRIPTION
git repack consolidates loose objects into pack files, improving storage efficiency and access time. It reorganizes the repository's object database by combining individual loose objects into compressed packs.
Repacking is useful after many small commits or after importing objects. The `-a -d` combination is common for aggressive repacking that removes redundant packs.
PARAMETERS
-a
Pack all objects.-A
Pack all reachable objects.-d
Remove redundant packs.-f
Force delta recomputation.--depth n
Delta chain depth.--window n
Delta window size.--geometric factor
Geometric repacking.-l
Local objects only.
SEE ALSO
git-gc(1), git-prune-packed(1)
