summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTyler Ang-Wanek <tylerw@axosoft.com>2019-07-02 10:14:46 -0700
committerTyler Ang-Wanek <tylerw@axosoft.com>2019-07-02 10:14:46 -0700
commit8f68ad9df1b707bce1b5cd2cba3a00c6e87e5b15 (patch)
treea0cc477bc45bc23e233fc2266c9214347f2cb17e
parenta5d4237c918aefb181dcb85acb7167ba09f8737b (diff)
downloadlibgit2-8f68ad9df1b707bce1b5cd2cba3a00c6e87e5b15.tar.gz
documentation: add small explanation for commit signing
-rw-r--r--include/git2/commit.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/git2/commit.h b/include/git2/commit.h
index 230448436..e6c4656a9 100644
--- a/include/git2/commit.h
+++ b/include/git2/commit.h
@@ -507,7 +507,13 @@ GIT_EXTERN(int) git_commit_dup(git_commit **out, git_commit *source);
*
* The callback will be called with the commit content, giving a user an
* opportunity to sign the commit content. The signature_field
- * buf may be left empty to specify the default field.
+ * buf may be left empty to specify the default field "gpgsig".
+ *
+ * Signatures can take the form of any string, and can be created on an arbitrary
+ * header field. Signatures are most commonly used for verifying authorship of a
+ * commit using GPG or a similar cryptographically secure signing algorithm.
+ * See https://git-scm.com/book/en/v2/Git-Tools-Signing-Your-Work for more
+ * details.
*
* When the callback:
* - returns GIT_PASSTHROUGH, no signature will be added to the commit.