From 280084d6aa8fb2a03f29aa0bc90c9b08eb3cb4e0 Mon Sep 17 00:00:00 2001
From: wing328 You can use also Supported config options can be different per language. Running config.yml
with following equivalent example:apiPackage: "petstore"
+
config-help -g {lang}
will show available options.
-These options are applied via configuration file (e.g. config.json) or by passing them with -D{optionName}={optionValue}
. (If -D{optionName}
does not work, please open a ticket and we'll look into it)-D{optionName}={optionValue}
. (If -D{optionName}
does not work, please open a ticket and we'll look into it)
java -jar modules/openapi-generator-cli/target/openapi-generator-cli.jar config-help -g java
Output
@@ -246,6 +249,12 @@ TypeScriptNodeClientCodegen.java "library":"feign" } +Or if you preffer yaml format it can look like
+groupId: "com.my.company"
+artifactId: "MyClient"
+artifactVersion: "1.2.0"
+library: "feign"
+
For all the unspecified options default values will be used.
Another way to override default options is to extend the config class for the specific language.
To change, for example, the prefix for the Objective-C generated files, simply subclass the ObjcClientCodegen.java
:
or
--import-mappings Pet=my.models.MyPet --import-mappings Order=my.models.MyOrder
-