swagger-api / swagger-api/swagger-codegen
[erlang][codegen] erlang-server generate does not respect packageName
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
Description
When generating erlang-server code, setting the packageName option does not affect the generated code. i.e. all modules are generated with a "swagger_" prefix, as compared to what you set the packageName to.
Swagger-codegen version
master
Swagger declaration file content or url
Command line used for generation
$ java -jar swagger-codegen-cli.jar generate -i $YAML -l erlang-server
--additional-properties packageName=$PACKAGE
Steps to reproduce
The above does not lead to erlang modules being generated named $PACKGE_router.erl but the un-parameterised swagger_router.erl
Related issues/PRs
Suggest a fix/enhancement
I will submit a fix shortly
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the erlang-server generator entry point used by the swagger-codegen CLI and trace how the packageName additional property reaches generated module names. Reproduce the command from the issue, then verify that generated modules use the configured packageName instead of the swagger_ prefix.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- erlang
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100