aboutsummaryrefslogtreecommitdiffstats
path: root/cache.h
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-07-30 00:58:28 -0700
committerJunio C Hamano <junkio@cox.net>2005-07-31 11:58:49 -0700
commit5da5c8f4cf4fb4e1cbccca4e7cebe70b77cf0b00 (patch)
tree329b5863cdb047fec0633d13bebfdfeb19c21a69 /cache.h
parent60036a41e1f25ee3e89142fa92e203dbbc6145cc (diff)
downloadgit-5da5c8f4cf4fb4e1cbccca4e7cebe70b77cf0b00.tar.gz
Teach parse_commit_buffer about grafting.
Introduce a new file $GIT_DIR/info/grafts (or $GIT_GRAFT_FILE) which is a list of "fake commit parent records". Each line of this file is a commit ID, followed by parent commit IDs, all 40-byte hex SHA1 separated by a single SP in between. The records override the parent information we would normally read from the commit objects, allowing both adding "fake" parents (i.e. grafting), and pretending as if a commit is not a child of some of its real parents (i.e. cauterizing). Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index d1bdb56355..a3c279d008 100644
--- a/cache.h
+++ b/cache.h
@@ -127,10 +127,12 @@ extern unsigned int active_nr, active_alloc, active_cache_changed;
#define DEFAULT_GIT_DIR_ENVIRONMENT ".git"
#define DB_ENVIRONMENT "GIT_OBJECT_DIRECTORY"
#define INDEX_ENVIRONMENT "GIT_INDEX_FILE"
+#define GRAFT_ENVIRONMENT "GIT_GRAFT_FILE"
extern char *get_object_directory(void);
extern char *get_refs_directory(void);
extern char *get_index_file(void);
+extern char *get_graft_file(void);
#define ALTERNATE_DB_ENVIRONMENT "GIT_ALTERNATE_OBJECT_DIRECTORIES"