Skip to content

[Erlang][Server] Add two options: packageName and openAPISpecName #1303

Merged
wing328 merged 3 commits intoOpenAPITools:masterfrom
feihongmeilian:master
Oct 24, 2018
Merged

[Erlang][Server] Add two options: packageName and openAPISpecName #1303
wing328 merged 3 commits intoOpenAPITools:masterfrom
feihongmeilian:master

Conversation

@feihongmeilian
Copy link
Copy Markdown
Contributor

packageName : Specify the prefix to the erl file that generate by openapi-generator.
openAPISpecName : Specify the json file name generated by yaml file

@wing328
Copy link
Copy Markdown
Member

wing328 commented Oct 24, 2018

@feihongmeilian the change looks good to me.

cc @tsloughter

get_openapi_path() ->
{ok, AppName} = application:get_application(?MODULE),
filename:join({{packageName}}_utils:priv_dir(AppName), "openapi.json").
filename:join({{packageName}}_utils:priv_dir(AppName), "{{openAPISpecName}}.json").
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use {{{openAPISpecName}}} instead to obtain the original value.

Copy link
Copy Markdown
Member

@wing328 wing328 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (the Travis CI failure is not related to this PR)

@wing328 wing328 merged commit 24ea884 into OpenAPITools:master Oct 24, 2018
@wing328 wing328 changed the title For erlang-server. add two options: packageName and openAPISpecName [Erlang][Server] Add two options: packageName and openAPISpecName Oct 24, 2018
@wing328
Copy link
Copy Markdown
Member

wing328 commented Oct 31, 2018

A-Joshi pushed a commit to ihsmarkitoss/openapi-generator that referenced this pull request Feb 27, 2019
…penAPITools#1303)

* Implement the ability to read packageName and openAPISpecName from a json file

* Replace '{{openAPISpecName}}' with '{{{openAPISpecName}}}'

* Update erlang-petstore-server
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants