diff --git a/cmd/gorepomod/internal/edit/editor.go b/cmd/gorepomod/internal/edit/editor.go index 0db343565..f0685d709 100644 --- a/cmd/gorepomod/internal/edit/editor.go +++ b/cmd/gorepomod/internal/edit/editor.go @@ -34,7 +34,7 @@ func (e *Editor) run(args ...string) error { if e.doIt { out, err := c.CombinedOutput() if err != nil { - return fmt.Errorf("failed to run go mod command in %s: %s (stdout=%q)", e.module.ShortName(), err.Error(), out) + return fmt.Errorf("failed to run go mod command in %s: %w (stdout=%q)", e.module.ShortName(), err, out) } } else { fmt.Printf("in %-60s; %s\n", c.Dir, c.String())