diff --git a/cobra/cmd/init.go b/cobra/cmd/init.go index 6e4c4f1..dbdc25b 100644 --- a/cobra/cmd/init.go +++ b/cobra/cmd/init.go @@ -116,8 +116,7 @@ type CurDir struct { } func goGet(mod string) error { - cmd := exec.Command("go", "get", mod) - return cmd.Run() + return exec.Command("go", "get", mod).Run() } func modInfoJSON(args ...string) []byte {