Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions src/sync.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ This merge was created using https://github.com/rust-lang/josh-sync.

// Merge the fetched commit.
// It is useful to print stdout/stderr here, because it shows the git diff summary
stream_command(
if let Err(error) = stream_command(
&[
"git",
"merge",
Expand All @@ -189,7 +189,16 @@ This merge was created using https://github.com/rust-lang/josh-sync.
],
self.verbose,
)
.context("FAILED to merge new commits, something went wrong")?;
.context("FAILED to merge new commits, something went wrong")
{
eprintln!(
r"The merge was unsuccessful (maybe there was a conflict?).
NOT rolling back the branch state, so you can examine it manually.
After you fix the conflicts, `git add` the changes and run `git merge --continue`."
);
git_reset.disarm();
return Err(RustcPullError::PullFailed(error));
}

// Now detect if something has actually been pulled
let current_sha = get_current_head_sha(self.verbose)?;
Expand Down