Skip to content

Commit

Permalink
do not abort merge when patch fails (#51)
Browse files Browse the repository at this point in the history
  • Loading branch information
bates64 committed Aug 6, 2023
2 parents ebf010c + 74d3d2a commit 646ce92
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions src/package.rs
Original file line number Diff line number Diff line change
Expand Up @@ -198,17 +198,8 @@ impl Package {
.current_dir(&repo)
.status()?;
if !status.success() {
// The merge failed! Abort the merge and tell the user to fix it.
let status = Command::new("git")
.arg("am")
.arg("--abort")
.current_dir(&repo)
.status()?;
if !status.success() {
panic!("failed to abort merge");
}
bail!("failed to apply patches");
}
log::warn!("Failed to merge. Resolve merge conflicts (either using `git mergetool` or vscode's merge editor) and commit them to continue.");
}
Ok(())
}

Expand Down

0 comments on commit 646ce92

Please sign in to comment.