summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBen Straub <bs@github.com>2013-02-07 10:33:56 -0800
committerBen Straub <bs@github.com>2013-06-13 17:19:33 -0700
commitedcb6ee649b5f18586cfa61252e371fbaa72d090 (patch)
tree3ecb076c6eb213d8d237b8abc6b49d249036fe5e /include
parent168e9d746e906a900c55e2de161d8941baf2a2d2 (diff)
downloadlibgit2-edcb6ee649b5f18586cfa61252e371fbaa72d090.tar.gz
Introduce git_blame_buffer
Diffstat (limited to 'include')
-rw-r--r--include/git2/blame.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/git2/blame.h b/include/git2/blame.h
index 1dfff1719..7f0fb2617 100644
--- a/include/git2/blame.h
+++ b/include/git2/blame.h
@@ -153,6 +153,20 @@ GIT_EXTERN(int) git_blame_file(
/**
+ * Get blame data for a file that has been modified.
+ *
+ * @param out pointer that will receive the results object
+ * @param reference output from git_blame_file for the file in question
+ * @param buffer the (possibly) modified contents of the file
+ * @return 0 on success, or an error code. (use giterr_last for information
+ * about the error)
+ */
+GIT_EXTERN(int) git_blame_buffer(
+ git_blame_results **out,
+ git_blame_results *reference,
+ const char *buffer);
+
+/**
* Free memory allocated by git_blame.
*
* @param results results structure to free