mirror of
https://github.com/git/git.git
synced 2025-12-12 20:36:24 +01:00
log: clean unneeded objects during log --remerge-diff
The --remerge-diff option will need to create new blobs and trees representing the "automatic merge" state. If one is traversing a long project history, one can easily get hundreds of thousands of loose objects generated during `log --remerge-diff`. However, none of those loose objects are needed after we have completed our diff operation; they can be summarily deleted. Add a new helper function to tmp_objdir to discard all the contained objects, and call it after each merge is handled. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
db757e8b8d
commit
7b90ab467a
@@ -318,6 +318,9 @@ struct rev_info {
|
||||
|
||||
/* misc. flags related to '--no-kept-objects' */
|
||||
unsigned keep_pack_cache_flags;
|
||||
|
||||
/* Location where temporary objects for remerge-diff are written. */
|
||||
struct tmp_objdir *remerge_objdir;
|
||||
};
|
||||
|
||||
int ref_excluded(struct string_list *, const char *path);
|
||||
|
||||
Reference in New Issue
Block a user