[REQ][php-slim4] Reduce log noise
Created by: ybelenko
Is your feature request related to a problem? Please describe.
There is a noise in CLI output and FILES
because of AbstractAuthenticator.php
supporting file generation.
CLI output:
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/config/dev/example.inc.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/config/prod/example.inc.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Middleware/JsonBodyParserMiddleware.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/BaseModel.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - writing file samples/server/petstore/php-slim4/lib/Auth/AbstractAuthenticator.php
[main] INFO o.o.codegen.TemplateManager - Skipped samples/server/petstore/php-slim4/.openapi-generator-ignore (Skipped by supportingFiles options supplied by user.)
FILES
:
lib/Api/AbstractStoreApi.php
lib/Api/AbstractUserApi.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/Auth/AbstractAuthenticator.php
lib/BaseModel.php
lib/Middleware/JsonBodyParserMiddleware.php
lib/Model/ApiResponse.php
Describe the solution you'd like
This part can be wiped off entirely: https://github.com/OpenAPITools/openapi-generator/blob/6c40192706cf95329f03e4c80ea628fb32a8ecab/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/PhpSlim4ServerCodegen.java#L251-L258
with 3 lines replacement to postProcessSupportingFileData
:
if (objs.containsKey("hasAuthMethods") && Boolean.TRUE.equals(objs.get("hasAuthMethods"))) {
supportingFiles.add(new SupportingFile("abstract_authenticator.mustache", toSrcPath(authPackage, srcBasePath), toAbstractName("Authenticator") + ".php"));
}