diff --git a/pkg/commands/exec_live_default.go b/pkg/commands/exec_live_default.go index 0e43a6741..bb3ffcdc1 100644 --- a/pkg/commands/exec_live_default.go +++ b/pkg/commands/exec_live_default.go @@ -18,6 +18,7 @@ import ( // As return of output you need to give a string that will be written to stdin // NOTE: If the return data is empty it won't written anything to stdin func RunCommandWithOutputLiveWrapper(c *OSCommand, command string, output func(string) string) error { + c.Log.WithField("command", command).Info("RunCommand") cmd := c.ExecutableFromString(command) cmd.Env = append(cmd.Env, "LANG=en_US.UTF-8", "LC_ALL=en_US.UTF-8") diff --git a/pkg/commands/git.go b/pkg/commands/git.go index 7b37968ed..722c217a2 100644 --- a/pkg/commands/git.go +++ b/pkg/commands/git.go @@ -911,6 +911,7 @@ func (c *GitCommand) PrepareInteractiveRebaseCommand(baseSha string, todo string } cmdStr := fmt.Sprintf("git rebase --interactive --autostash --keep-empty %s", baseSha) + c.Log.WithField("command", cmdStr).Info("RunCommand") splitCmd := str.ToArgv(cmdStr) cmd := c.OSCommand.command(splitCmd[0], splitCmd[1:]...) diff --git a/pkg/gui/tasks_adapter.go b/pkg/gui/tasks_adapter.go index 0a05bb0c9..91ca92a79 100644 --- a/pkg/gui/tasks_adapter.go +++ b/pkg/gui/tasks_adapter.go @@ -2,12 +2,18 @@ package gui import ( "os/exec" + "strings" "github.com/jesseduffield/gocui" "github.com/jesseduffield/lazygit/pkg/tasks" ) func (gui *Gui) newCmdTask(viewName string, cmd *exec.Cmd) error { + gui.Log.WithField( + "command", + strings.Join(cmd.Args, " "), + ).Debug("RunCommand") + view, err := gui.g.View(viewName) if err != nil { return nil // swallowing for now