summaryrefslogtreecommitdiff
path: root/refs.h
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2006-12-26 23:47:40 -0800
committerJunio C Hamano <junkio@cox.net>2006-12-26 23:47:40 -0800
commite8b4029f990907e24fac0e7772ee19ee6dd55c1c (patch)
treeb3b799be8af66f36bd4a09d0b5ed3d8f03136dab /refs.h
parent268b827d9883e77f395a63e4afa10ebbac10bfcf (diff)
parent7dc269230761e32e663d9cd0b6f4c316466a490d (diff)
downloadgit-e8b4029f990907e24fac0e7772ee19ee6dd55c1c.tar.gz
Merge branch 'jc/fsck-reflog'
* jc/fsck-reflog: Add git-reflog to .gitignore reflog expire: do not punt on tags that point at non commits. reflog expire: prune commits that are not incomplete Don't crash during repack of a reflog with pruned commits. git reflog expire Move in_merge_bases() to commit.c reflog: fix warning message. Teach git-repack to preserve objects referred to by reflog entries. Protect commits recorded in reflog from pruning. add for_each_reflog_ent() iterator
Diffstat (limited to 'refs.h')
-rw-r--r--refs.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/refs.h b/refs.h
index 51aab1e6bf..de43cc768a 100644
--- a/refs.h
+++ b/refs.h
@@ -44,6 +44,10 @@ extern int write_ref_sha1(struct ref_lock *lock, const unsigned char *sha1, cons
/** Reads log for the value of ref during at_time. **/
extern int read_ref_at(const char *ref, unsigned long at_time, int cnt, unsigned char *sha1);
+/* iterate over reflog entries */
+typedef int each_reflog_ent_fn(unsigned char *osha1, unsigned char *nsha1, char *, void *);
+void for_each_reflog_ent(const char *ref, each_reflog_ent_fn fn, void *cb_data);
+
/** Returns 0 if target has the right format for a ref. **/
extern int check_ref_format(const char *target);