Skip to content

Commit

Permalink
Fix gocritic linter
Browse files Browse the repository at this point in the history
  • Loading branch information
tejal29 committed Mar 8, 2019
1 parent d3a71d8 commit 3ce11bf
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions pkg/skaffold/initializer/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,14 @@ func DoInit(out io.Writer, c Config) error {
return fmt.Errorf("pre-existing %s found", path)
}
logrus.Debugf("%s is a valid skaffold configuration: continuing since --force=true", path)
} else if IsSupportedKubernetesFormat(path) {
return nil
}
if IsSupportedKubernetesFormat(path) {
potentialConfigs = append(potentialConfigs, path)
} else if docker.ValidateDockerfile(path) {
// try and parse dockerfile
return nil
}
// try and parse dockerfile
if docker.ValidateDockerfile(path) {
logrus.Infof("existing dockerfile found: %s", path)
dockerfiles = append(dockerfiles, path)
}
Expand Down

0 comments on commit 3ce11bf

Please sign in to comment.