git_repository_message

Retrieve git's prepared message

Operations such as git revert/cherry-pick/merge with the -n option stop just short of creating a commit with the changes and save their prepared message in .git/MERGE_MSG so the next git-commit execution can present it to the user for them to amend if they wish.

Use this function to get the contents of this file. Don't forget to remove the file after you create the commit.

extern (C) nothrow @nogc
int
git_repository_message

Parameters

out_ libgit2_d.buffer.git_buf*

git_buf to write data into

repo libgit2_d.types.git_repository*

Repository to read prepared message from

Return Value

Type: int

0, git_error_code.GIT_ENOTFOUND if no message exists or an error code

Meta