Skip to content

Commit 8f68ad9

Browse files
committed
documentation: add small explanation for commit signing
1 parent a5d4237 commit 8f68ad9

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

include/git2/commit.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -507,7 +507,13 @@ GIT_EXTERN(int) git_commit_dup(git_commit **out, git_commit *source);
507507
*
508508
* The callback will be called with the commit content, giving a user an
509509
* opportunity to sign the commit content. The signature_field
510-
* buf may be left empty to specify the default field.
510+
* buf may be left empty to specify the default field "gpgsig".
511+
*
512+
* Signatures can take the form of any string, and can be created on an arbitrary
513+
* header field. Signatures are most commonly used for verifying authorship of a
514+
* commit using GPG or a similar cryptographically secure signing algorithm.
515+
* See https://git-scm.com/book/en/v2/Git-Tools-Signing-Your-Work for more
516+
* details.
511517
*
512518
* When the callback:
513519
* - returns GIT_PASSTHROUGH, no signature will be added to the commit.

0 commit comments

Comments
 (0)