diff options
author | Dana How <danahow@gmail.com> | 2007-05-09 13:56:50 -0700 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2007-05-10 15:23:09 -0700 |
commit | 960ccca6803c9fb57429d43572a9545a96107e32 (patch) | |
tree | fcacfbd86e9411c75313132a14562c35c2f83ca9 /Documentation/git-pack-objects.txt | |
parent | 479b56ba50144b30f28c5b225d412125c07def9f (diff) | |
download | git-960ccca6803c9fb57429d43572a9545a96107e32.tar.gz |
Custom compression levels for objects and packs
Add config variables pack.compression and core.loosecompression ,
and switch --compression=level to pack-objects.
Loose objects will be compressed using core.loosecompression if set,
else core.compression if set, else Z_BEST_SPEED.
Packed objects will be compressed using --compression=level if seen,
else pack.compression if set, else core.compression if set,
else Z_DEFAULT_COMPRESSION. This is the "pack compression level".
Loose objects added to a pack undeltified will be recompressed
to the pack compression level if it is unequal to the current
loose compression level by the preceding rules, or if the loose
object was written while core.legacyheaders = true. Newly
deltified loose objects are always compressed to the current
pack compression level.
Previously packed objects added to a pack are recompressed
to the current pack compression level exactly when their
deltification status changes, since the previous pack data
cannot be reused.
In either case, the --no-reuse-object switch from the first
patch below will always force recompression to the current pack
compression level, instead of assuming the pack compression level
hasn't changed and pack data can be reused when possible.
This applies on top of the following patches from Nicolas Pitre:
[PATCH] allow for undeltified objects not to be reused
[PATCH] make "repack -f" imply "pack-objects --no-reuse-object"
Signed-off-by: Dana L. How <danahow@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'Documentation/git-pack-objects.txt')
-rw-r--r-- | Documentation/git-pack-objects.txt | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/Documentation/git-pack-objects.txt b/Documentation/git-pack-objects.txt index ce892147dd..2531238df4 100644 --- a/Documentation/git-pack-objects.txt +++ b/Documentation/git-pack-objects.txt @@ -130,10 +130,22 @@ base-name:: --no-reuse-object:: This flag tells the command not to reuse existing object data at all, including non deltified object, forcing recompression of everything. - This implies --no-reuse-delta. Useful only in the obscur case where + This implies --no-reuse-delta. Useful only in the obscure case where wholesale enforcement of a different compression level on the packed data is desired. +--compression=[N]:: + Specifies compression level for newly-compressed data in the + generated pack. If not specified, pack compression level is + determined first by pack.compression, then by core.compression, + and defaults to -1, the zlib default, if neither is set. + Data copied from loose objects will be recompressed + if core.legacyheaders was true when they were created or if + the loose compression level (see core.loosecompression and + core.compression) is now a different value than the pack + compression level. Add --no-reuse-object if you want to force + a uniform compression level on all data no matter the source. + --delta-base-offset:: A packed archive can express base object of a delta as either 20-byte object name or as an offset in the |