summaryrefslogtreecommitdiff
path: root/include/git2/reflog.h
diff options
context:
space:
mode:
authornulltoken <emeric.fermas@gmail.com>2012-07-18 20:12:45 +0200
committernulltoken <emeric.fermas@gmail.com>2012-07-25 07:53:30 +0200
commitbd72425d16fce9771af7727029f7d8ea8c2e98d2 (patch)
treef4a9367ebf29fb7552faad8136dd68f1743212c0 /include/git2/reflog.h
parentd284b3de631edeaa651bf3ee2c5963cb970016c4 (diff)
downloadlibgit2-bd72425d16fce9771af7727029f7d8ea8c2e98d2.tar.gz
reflog: introduce git_reflog_write()
Diffstat (limited to 'include/git2/reflog.h')
-rw-r--r--include/git2/reflog.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/git2/reflog.h b/include/git2/reflog.h
index 1de870bba..9d04688e2 100644
--- a/include/git2/reflog.h
+++ b/include/git2/reflog.h
@@ -33,6 +33,15 @@ GIT_BEGIN_DECL
GIT_EXTERN(int) git_reflog_read(git_reflog **reflog, git_reference *ref);
/**
+ * Write an existing in-memory reflog object back to disk
+ * using an atomic file lock.
+ *
+ * @param reflog an existing reflog object
+ * @return 0 or an error code
+ */
+GIT_EXTERN(int) git_reflog_write(git_reflog *reflog);
+
+/**
* Add a new entry to the reflog for the given reference
*
* If there is no reflog file for the given