Skip to content

Commit e6bcad1

Browse files
ignassewJamie Tanna
andauthored
fix: print the warning message to stderr instead of stdout (#1895)
Co-authored-by: Jamie Tanna <jamie.tanna@elastic.co>
1 parent 5b71854 commit e6bcad1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

cmd/oapi-codegen/oapi-codegen.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ func main() {
297297
}
298298

299299
if strings.HasPrefix(swagger.OpenAPI, "3.1.") {
300-
fmt.Println("WARNING: You are using an OpenAPI 3.1.x specification, which is not yet supported by oapi-codegen (https://github.com/oapi-codegen/oapi-codegen/issues/373) and so some functionality may not be available. Until oapi-codegen supports OpenAPI 3.1, it is recommended to downgrade your spec to 3.0.x")
300+
fmt.Fprintln(os.Stderr, "WARNING: You are using an OpenAPI 3.1.x specification, which is not yet supported by oapi-codegen (https://github.com/oapi-codegen/oapi-codegen/issues/373) and so some functionality may not be available. Until oapi-codegen supports OpenAPI 3.1, it is recommended to downgrade your spec to 3.0.x")
301301
}
302302

303303
if len(noVCSVersionOverride) > 0 {

0 commit comments

Comments
 (0)