Skip to content

Commit

Permalink
Merge branch 'master' into docusaurus
Browse files Browse the repository at this point in the history
* master: (52 commits)
  Support for "x-enum-descriptions" (OpenAPITools#1752)
  add new sample files
  Add a checklist to issue report (OpenAPITools#1851)
  Fix typo in template (OpenAPITools#1859)
  update samples
  add isModel to updatebooleanflagwithcodegenproperty (OpenAPITools#1844)
  [python-client] Add model default values (OpenAPITools#1776)
  fix: force to decode as utf-8 when header contains application/json to avoid text garbling. (OpenAPITools#1700)
  Better support for composed schema (allOf) (OpenAPITools#1842)
  Add additional properties to Java CodegenModel (OpenAPITools#1854)
  Minor Angular type improvements (OpenAPITools#1843)
  [DART] fix: set fields to null if json value is null. (OpenAPITools#1798)
  add options to maven plugin (OpenAPITools#1845)
  fix unqiue name in handling forward slash (OpenAPITools#1839)
  better handle of oauth (OpenAPITools#1838)
  [C] Support for authentication methods (OpenAPITools#1628)
  better error message when parameter ref not defined (OpenAPITools#1837)
  Add links to articles about openapi generator
  Add a link to @watiko article
  Delete langs command (OpenAPITools#1836)
  ...
  • Loading branch information
jimschubert committed Jan 9, 2019
2 parents 9563e8e + d584833 commit 0750ef9
Show file tree
Hide file tree
Showing 993 changed files with 37,766 additions and 11,419 deletions.
8 changes: 8 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Expand Up @@ -7,6 +7,14 @@ assignees: ''

---

#### Bug Report Checklist

- [ ] Have you provided a full/minimal spec to reproduce the issue?
- [ ] What's the version of OpenAPI Generator used?
- [ ] Have you search for related issues/PRs?
- [ ] What's the actual output vs expected output?
- [ ] [Optional] Bounty to sponsor the fix ([example](https://www.bountysource.com/issues/66123212-javascript-client-produces-a-wrong-object-for-a-string-enum-type-that-is-used-with-ref))

<!--
Please follow the issue template below for bug reports.
Also please indicate in the issue title which language/library is concerned. Eg: [BUG][JAVA] Bug generating foo with bar
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Expand Up @@ -27,6 +27,7 @@ packages/
.packages
.vagrant/
.vscode/
**/.vs

.settings

Expand Down Expand Up @@ -128,7 +129,6 @@ samples/client/petstore/swift3/**/SwaggerClientTests/Podfile.lock
# C#
*.csproj.user
samples/client/petstore/csharp/SwaggerClient/IO.Swagger.userprefs
samples/client/petstore/csharp/SwaggerClientTest/.vs
samples/client/petstore/csharp/SwaggerClientTest/obj
samples/client/petstore/csharp/SwaggerClientTest/bin
samples/client/petstore/csharp/SwaggerClientTest/packages
Expand Down
12 changes: 8 additions & 4 deletions README.md
Expand Up @@ -504,6 +504,7 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in
- [b<>com](https://b-com.com/en)
- [Bithost GmbH](https://www.bithost.ch)
- [Boxever](https://www.boxever.com/)
- [GenFlow](https://github.com/RepreZen/GenFlow)
- [GMO Pepabo](https://pepabo.com/en/)
- [JustStar](https://www.juststarinfo.com)
- [Klarna](https://www.klarna.com/)
Expand All @@ -529,9 +530,12 @@ Here are some companies/projects (alphabetical order) using OpenAPI Generator in
- 2018/06/27 - [Lessons Learned from Leading an Open-Source Project Supporting 30+ Programming Languages](https://speakerdeck.com/wing328/lessons-learned-from-leading-an-open-source-project-supporting-30-plus-programming-languages) - [William Cheng](https://github.com/wing328) at [LinuxCon + ContainerCon + CloudOpen China 2018](http://bit.ly/2waDKKX)
- 2018/07/19 - [OpenAPI Generator Contribution Quickstart - RingCentral Go SDK](https://medium.com/ringcentral-developers/openapi-generator-for-go-contribution-quickstart-8cc72bf37b53) by [John Wang](https://github.com/grokify)
- 2018/08/22 - [OpenAPI Generatorのプロジェクト構成などのメモ](https://yinm.info/20180822/) by [Yusuke Iinuma](https://github.com/yinm)
- 2018/09/12 - [RepreZen and OpenAPI 3.0: Now is the Time](https://www.reprezen.com/blog/reprezen-openapi-3.0-upgrade-now-is-the-time) by [Miles Daffin](https://www.reprezen.com/blog/author/miles-daffin)
- 2018/10/31 - [A node package wrapper for openapi-generator](https://github.com/HarmoWatch/openapi-generator-cli)
- 2018/11/03 - [OpenAPI Generator + golang + Flutter でアプリ開発](http://ryuichi111std.hatenablog.com/entry/2018/11/03/214005) by [Ryuichi Daigo](https://github.com/ryuichi111)
- 2018/11/19 - [OpenAPIs are everywhere](https://youtu.be/-lDot4Yn7Dg) by [Jeremie Bresson (Unblu)](https://github.com/jmini) at [EclipseCon Europe 2018](https://www.eclipsecon.org/europe2018)
- 2018/12/09 - [openapi-generator をカスタマイズする方法](https://qiita.com/watiko/items/0961287c02eac9211572) by [@watiko](https://qiita.com/watiko)
- 2019/01/03 - [Calling a Swagger service from Apex using openapi-generator](https://lekkimworld.com/2019/01/03/calling-a-swagger-service-from-apex-using-openapi-generator/) by [Mikkel Flindt Heisterberg](https://lekkimworld.com)

## [6 - About Us](#table-of-contents)

Expand Down Expand Up @@ -566,7 +570,7 @@ Here is a list of template creators:
* Dart 2: @swipesight
* Dart (Jaguar): @jaumard
* Elixir: @niku
* Elm: @trenneman
* Elm: @eriktim
* Eiffel: @jvelilla
* Erlang: @tsloughter
* Erlang (PropEr): @jfacorro @robertoaloi
Expand Down Expand Up @@ -692,8 +696,8 @@ If you want to join the committee, please kindly apply by sending an email to te
| Clojure | |
| Dart | @ircecho (2017/07) @swipesight (2018/09) @jaumard (2018/09) |
| Eiffel | @jvelilla (2017/09) |
| Elixir | |
| Elm | @trenneman (2018/09) |
| Elixir | @mrmstn (2018/12) |
| Elm | @eriktim (2018/09) |
| Erlang | @tsloughter (2017/11) @jfacorro (2018/10) @robertoaloi (2018/10) |
| Go | @antihax (2017/11) @bvwells (2017/12) @grokify (2018/07) @kemokemo (2018/09 |
| GraphQL | @renepardon (2018/12) |
Expand Down Expand Up @@ -732,7 +736,7 @@ OpenAPI Generator is a fork of [Swagger Codegen](https://github.com/swagger-api/
- [Daiki Matsudate](https://github.com/d-date)
- [Daniel](https://github.com/Danielku15)
- [Emiliano Bonassi](https://github.com/emilianobonassi)
- [Erik Timmers](https://github.com/trenneman)
- [Erik Timmers](https://github.com/eriktim)
- [Esteban Marin](https://github.com/macjohnny)
- [Gustavo Paz](https://github.com/gustavoapaz)
- [Javier Velilla](https://github.com/jvelilla)
Expand Down
3 changes: 1 addition & 2 deletions bin/javascript-es6-petstore.sh
Expand Up @@ -29,7 +29,6 @@ fi
export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties"
ags="generate -t modules/openapi-generator/src/main/resources/Javascript/es6 \
-i modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -g javascript \
-o samples/client/petstore/javascript-es6 \
--additional-properties useES6=true $@"
-o samples/client/petstore/javascript-es6 $@"

java -DappName=PetstoreClient $JAVA_OPTS -jar $executable $ags
2 changes: 1 addition & 1 deletion docker-entrypoint.sh
Expand Up @@ -12,7 +12,7 @@ codegen="${cli}/target/openapi-generator-cli.jar"
# We code in a list of commands here as source processing is potentially buggy (requires undocumented conventional use of annotations).
# A list of known commands helps us determine if we should compile CLI. There's an edge-case where a new command not added to this
# list won't be considered a "real" command. We can get around that a bit by checking CLI completions beforehand if it exists.
commands="list,generate,meta,langs,help,config-help,validate,version"
commands="list,generate,meta,help,config-help,validate,version"

# if CLI jar exists, check $1 against completions available in the CLI
if [[ -f "${codegen}" && -n "$(java ${JAVA_OPTS} -jar "${codegen}" completion | grep "^$1\$" )" ]]; then
Expand Down
2 changes: 1 addition & 1 deletion docs/generators/javascript.md
Expand Up @@ -26,5 +26,5 @@ sidebar_label: javascript
|emitJSDoc|generate JSDoc comments| |true|
|useInheritance|use JavaScript prototype chains &amp; delegation for inheritance| |true|
|hideGenerationTimestamp|Hides the generation timestamp when files are generated.| |true|
|useES6|use JavaScript ES6 (ECMAScript 6) (beta). Default is ES5.| |false|
|useES6|use JavaScript ES6 (ECMAScript 6) (beta). Default is ES6.| |true|
|modelPropertyNaming|Naming convention for the property: 'camelCase', 'PascalCase', 'snake_case' and 'original', which keeps the original name| |camelCase|
2 changes: 1 addition & 1 deletion docs/migration-from-swagger-codegen.md
Expand Up @@ -159,7 +159,7 @@ Corresponding java code: `CodegenProperty.datatype` is renamed to `CodegenProper
`.swagger-codegen-ignore` is replaced by `.openapi-generator-ignore`.
The syntax inside the file stays the same.

You don't need to rename the file manually, OpenAPI Generator will do it when your run it against an existing an existing output directory.
You don't need to rename the file manually, OpenAPI Generator will do it when your run it against an existing output directory.
(When there is no `.openapi-generator-ignore` in a folder, if a `.swagger-codegen-ignore` file is present it will be considered and renamed to `.openapi-generator-ignore`).


Expand Down
2 changes: 1 addition & 1 deletion docs/migration-guide.adoc
Expand Up @@ -20,7 +20,7 @@ Version `4.0.0` is a major release, which contains some breaking changes without
The option is replaced with `-g` (`--generator-name`).

* `-g` allows the same values as `-l`
* See `langs` command for the list of generator name
* See `list` command for the list of generator name

=== From 3.1.x to 3.2.0

Expand Down
Expand Up @@ -50,7 +50,7 @@ public class Generate implements Runnable {
private Boolean verbose;

@Option(name = {"-g", "--generator-name"}, title = "generator name",
description = "generator to use (see langs command for list)")
description = "generator to use (see list command for list)")
private String generatorName;

@Option(name = {"-o", "--output"}, title = "output directory",
Expand Down Expand Up @@ -208,6 +208,9 @@ public class Generate implements Runnable {
@Option(name = {"--enable-post-process-file"}, title = "enable post-process file", description = CodegenConstants.ENABLE_POST_PROCESS_FILE)
private Boolean enablePostProcessFile;

@Option(name = {"--generate-alias-as-model"}, title = "generate alias (array, map) as model", description = CodegenConstants.GENERATE_ALIAS_AS_MODEL_DESC)
private Boolean generateAliasAsModel;

@Override
public void run() {
if (logToStderr != null) {
Expand Down Expand Up @@ -334,6 +337,10 @@ public void run() {
configurator.setEnablePostProcessFile(enablePostProcessFile);
}

if (generateAliasAsModel != null) {
configurator.setGenerateAliasAsModel(generateAliasAsModel);
}

applySystemPropertiesKvpList(systemProperties, configurator);
applyInstantiationTypesKvpList(instantiationTypes, configurator);
applyImportMappingsKvpList(importMappings, configurator);
Expand Down

This file was deleted.

0 comments on commit 0750ef9

Please sign in to comment.