diff options
author | Carlos Martín Nieto <cmn@dwim.me> | 2018-03-22 16:35:23 +0100 |
---|---|---|
committer | Carlos Martín Nieto <cmn@dwim.me> | 2018-03-22 16:35:23 +0100 |
commit | 37a0165f8d8c271e334b6544947b00e12a0c24d9 (patch) | |
tree | d08993e434b7f0027d871839e6061162c7049ad6 | |
parent | e8eba1cfd86d04fc21c52624aa0b21ab0f9b0cb6 (diff) | |
download | libgit2-37a0165f8d8c271e334b6544947b00e12a0c24d9.tar.gz |
examples: adjust merge to git_commit_create_oncmn/commit-on
This should be a good place to eventually make use of `_fromstate` depending on
what we're trying to show in this example.
-rw-r--r-- | examples/merge.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/examples/merge.c b/examples/merge.c index 59982cb9b..e70740608 100644 --- a/examples/merge.c +++ b/examples/merge.c @@ -285,12 +285,12 @@ static int create_merge_commit(git_repository *repo, git_index *index, merge_opt check_lg2(git_tree_lookup(&tree, repo, &tree_oid), "failed to lookup tree", NULL); /* Commit time ! */ - err = git_commit_create(&commit_oid, - repo, git_reference_name(head_ref), - sign, sign, - NULL, msg, - tree, - opts->annotated_count + 1, (const git_commit **)parents); + err = git_commit_create_on(&commit_oid, + repo, git_reference_name(head_ref), + sign, sign, + NULL, msg, + tree, + opts->annotated_count + 1, (const git_commit **)parents); check_lg2(err, "failed to create commit", NULL); /* We're done merging, cleanup the repository state */ |