summaryrefslogtreecommitdiff
path: root/commit.h
diff options
context:
space:
mode:
authorDerrick Stolee <dstolee@microsoft.com>2018-08-20 18:24:30 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-08-21 17:22:51 (GMT)
commit20fd6d57996e33c30b6bb030329523d0116f15ec (patch)
treeba237151d6d0d2f2a3e83802dda069c7789b8bbf /commit.h
parentd6538246d3d4edbfbc9b0af6a2aa38552d35f7f1 (diff)
downloadgit-20fd6d57996e33c30b6bb030329523d0116f15ec.zip
git-20fd6d57996e33c30b6bb030329523d0116f15ec.tar.gz
git-20fd6d57996e33c30b6bb030329523d0116f15ec.tar.bz2
commit-graph: not compatible with grafts
Augment commit_graph_compatible(r) to return false when the given repository r has commit grafts or is a shallow clone. Test that in these situations we ignore existing commit-graph files and we do not write new commit-graph files. Helped-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit.h')
-rw-r--r--commit.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/commit.h b/commit.h
index da0db36..5459e27 100644
--- a/commit.h
+++ b/commit.h
@@ -202,6 +202,7 @@ typedef int (*each_commit_graft_fn)(const struct commit_graft *, void *);
struct commit_graft *read_graft_line(struct strbuf *line);
int register_commit_graft(struct repository *r, struct commit_graft *, int);
+void prepare_commit_graft(struct repository *r);
struct commit_graft *lookup_commit_graft(struct repository *r, const struct object_id *oid);
extern struct commit_list *get_merge_bases(struct commit *rev1, struct commit *rev2);