File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -137,6 +137,10 @@ func (c *migrateCommand) preRunE(cmd *cobra.Command, _ []string) error {
137
137
return fmt .Errorf ("unsupported format: %s" , c .opts .format )
138
138
}
139
139
140
+ if c .cfg .Version != "" {
141
+ return fmt .Errorf ("configuration version is already set: %s" , c .cfg .Version )
142
+ }
143
+
140
144
if c .opts .skipValidation {
141
145
return nil
142
146
}
@@ -147,10 +151,6 @@ func (c *migrateCommand) preRunE(cmd *cobra.Command, _ []string) error {
147
151
os .Exit (exitcodes .NoConfigFileDetected )
148
152
}
149
153
150
- if c .cfg .Version != "" {
151
- return fmt .Errorf ("configuration version is already set: %s" , c .cfg .Version )
152
- }
153
-
154
154
c .log .Infof ("Validating v1 configuration file: %s" , usedConfigFile )
155
155
156
156
err := validateConfiguration ("https://golangci-lint.run/jsonschema/golangci.v1.jsonschema.json" , usedConfigFile )
You can’t perform that action at this time.
0 commit comments