I refactored template management in #6357. @wing328 found that an issue I had with one of the rust files was because the file was being processed by Mustache where it hadn't been before. This PR updates to process only files with an ending supported by the targeted templating engine.
This also fixes some Sonar recommendations, one of which may be a breaking change; template and output directories now may not include ..
for directory traversals.
cc @OpenAPITools/generator-core-team
PR checklist
-
Read the contribution guidelines. -
If contributing template-only or documentation-only changes which will change sample output, build the project beforehand. -
Run the shell script ./bin/generate-samples.sh
to update all Petstore samples related to your fix. This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master. These must match the expectations made by your contribution. You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example./bin/generate-samples.sh bin/config/java*
. -
File the PR against the correct branch: master
,4.3.x
,5.0.x
. Default:master
. -
Copy the technical committee to review the pull request if your PR is targeting a particular programming language.