Skip to content
Permalink
Browse files
fix(git): fast, ad-hoc fix, return exec.ExitError from gitCmd.Run()
  • Loading branch information
distorhead committed Jan 19, 2022
1 parent 0c1fcf0 commit d737d8bbfd216ad9ea068550e625a0b8c1f0c570
Showing with 2 additions and 1 deletion.
  1. +2 −1 pkg/true_git/git_cmd.go
@@ -63,7 +63,8 @@ func (c *GitCmd) Run(ctx context.Context) error {

switch err := c.Cmd.Run(); err.(type) {
case *exec.ExitError:
return fmt.Errorf("error running command %q: %s\nStdout:\n%s\nStderr:\n%s", c, err, c.OutBuf, c.ErrBuf)
// return fmt.Errorf("error running command %q: %s\nStdout:\n%s\nStderr:\n%s", c, err, c.OutBuf, c.ErrBuf)
return err
case error:
return fmt.Errorf("error running command %q: %s", c, err)
}

0 comments on commit d737d8b

Please sign in to comment.