mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2025-12-11 22:02:32 +01:00
Merge commit 'ba83466e1d'
This commit is contained in:
commit
f217e4a39a
11 changed files with 97 additions and 59 deletions
|
|
@ -239,4 +239,12 @@ PushRemotePtr GetPushRemote(git_repository* repo, const git_reference* local) {
|
|||
return PushRemotePtr(res.release());
|
||||
}
|
||||
|
||||
CommitMessage GetCommitMessage(git_repository* repo, const git_oid& id) {
|
||||
git_commit* commit;
|
||||
VERIFY(!git_commit_lookup(&commit, repo, &id)) << GitError();
|
||||
ON_SCOPE_EXIT(=) { git_commit_free(commit); };
|
||||
return {.encoding = git_commit_message_encoding(commit) ?: "",
|
||||
.summary = git_commit_summary(commit) ?: ""};
|
||||
}
|
||||
|
||||
} // namespace gitstatus
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue