Skip to content

Commit

Permalink
Address code review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Priya Wadhwa committed Oct 3, 2018
1 parent 1c4780f commit eb06f39
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/skaffold/deploy/kubectl/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ package kubectl
import (
"context"
"encoding/json"
"fmt"
"os/exec"
"strconv"

"github.com/GoogleContainerTools/skaffold/pkg/skaffold/util"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
)

Expand Down Expand Up @@ -52,10 +52,10 @@ func (v ClientVersion) String() string {
func (c *CLI) CheckVersion() error {
m, err := strconv.Atoi(c.Version().Minor)
if err != nil {
return fmt.Errorf("couldn't get kubectl minor version: %v", err)
return errors.Wrap(err, "couldn't get kubectl minor version")
}
if m < 12 {
return fmt.Errorf("kubectl version 1.12.0 or greater is recommended for use with skaffold")
return errors.New("kubectl version 1.12.0 or greater is recommended for use with skaffold")
}
return nil
}
Expand Down

0 comments on commit eb06f39

Please sign in to comment.