summaryrefslogtreecommitdiff
path: root/refs.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2015-08-25 14:57:08 -0700
committerJunio C Hamano <gitster@pobox.com>2015-08-25 14:57:08 -0700
commit080cc646637f20494138c62fe6b8b0fee8d521fa (patch)
tree96ce9628c94c3d2e8abec42121da60e9c05c09b1 /refs.h
parent32561f5dd39da3ac720f6778bc2e8aafed771eb5 (diff)
parent2c3aed1381f22494bc06fd66dec8292a296db10f (diff)
downloadgit-080cc646637f20494138c62fe6b8b0fee8d521fa.tar.gz
Merge branch 'dt/refs-pseudo'
To prepare for allowing a different "ref" backend to be plugged in to the system, update_ref()/delete_ref() have been taught about ref-like things like MERGE_HEAD that are per-worktree (they will always be written to the filesystem inside $GIT_DIR). * dt/refs-pseudo: pseudoref: check return values from read_ref() sequencer: replace write_cherry_pick_head with update_ref bisect: use update_ref pseudorefs: create and use pseudoref update and delete functions refs: add ref_type function refs: introduce pseudoref and per-worktree ref concepts
Diffstat (limited to 'refs.h')
-rw-r--r--refs.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/refs.h b/refs.h
index 6a3fa6d41d..e9a5f3230a 100644
--- a/refs.h
+++ b/refs.h
@@ -445,6 +445,14 @@ extern int parse_hide_refs_config(const char *var, const char *value, const char
extern int ref_is_hidden(const char *);
+enum ref_type {
+ REF_TYPE_PER_WORKTREE,
+ REF_TYPE_PSEUDOREF,
+ REF_TYPE_NORMAL,
+};
+
+enum ref_type ref_type(const char *refname);
+
enum expire_reflog_flags {
EXPIRE_REFLOGS_DRY_RUN = 1 << 0,
EXPIRE_REFLOGS_UPDATE_REF = 1 << 1,