Skip to content

Commit a11c0b5

Browse files
authored
Use libgit2 to get the merge commit message. (#755)
1 parent 53f65c8 commit a11c0b5

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

asyncgit/src/sync/merge.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
use std::fs::read_to_string;
2-
31
use crate::{
42
error::{Error, Result},
53
sync::{
@@ -82,10 +80,7 @@ pub fn merge_msg(repo_path: &str) -> Result<String> {
8280
scope_time!("merge_msg");
8381

8482
let repo = utils::repo(repo_path)?;
85-
86-
let msg_file = repo.path().join("MERGE_MSG");
87-
88-
let content = read_to_string(msg_file).unwrap_or_default();
83+
let content = repo.message()?;
8984

9085
Ok(content)
9186
}

0 commit comments

Comments
 (0)