summaryrefslogtreecommitdiffstats
path: root/pkg/gui/rebase_options_panel.go
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2021-04-10 16:01:46 +1000
committerJesse Duffield <jessedduffield@gmail.com>2021-04-11 17:07:49 +1000
commitbb918b579a3073d786fda83a2bc11c602e442aa0 (patch)
treefe126f12a88db9a9e119d0b172c0902bc0f49244 /pkg/gui/rebase_options_panel.go
parente145090046e1693e2100cb0a0ab40a271705f4b0 (diff)
start adding support for logging of commands
Diffstat (limited to 'pkg/gui/rebase_options_panel.go')
-rw-r--r--pkg/gui/rebase_options_panel.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/pkg/gui/rebase_options_panel.go b/pkg/gui/rebase_options_panel.go
index b1bcf1e7a..c49b4f38f 100644
--- a/pkg/gui/rebase_options_panel.go
+++ b/pkg/gui/rebase_options_panel.go
@@ -43,18 +43,20 @@ func (gui *Gui) genericMergeCommand(command string) error {
return gui.createErrorPanel(gui.Tr.NotMergingOrRebasing)
}
+ gitCommand := gui.GitCommand.WithSpan(fmt.Sprintf("Merge: %s", command))
+
commandType := strings.Replace(status, "ing", "e", 1)
// we should end up with a command like 'git merge --continue'
// it's impossible for a rebase to require a commit so we'll use a subprocess only if it's a merge
if status == commands.REBASE_MODE_MERGING && command != "abort" && gui.Config.GetUserConfig().Git.Merging.ManualCommit {
- sub := gui.OSCommand.PrepareSubProcess("git", commandType, fmt.Sprintf("--%s", command))
+ sub := gitCommand.OSCommand.PrepareSubProcess("git", commandType, fmt.Sprintf("--%s", command))
if sub != nil {
return gui.runSubprocessWithSuspenseAndRefresh(sub)
}
return nil
}
- result := gui.GitCommand.GenericMergeOrRebaseAction(commandType, command)
+ result := gitCommand.GenericMergeOrRebaseAction(commandType, command)
if err := gui.handleGenericMergeCommandResult(result); err != nil {
return err
}