From 69148bf168c213f7211a6cdf41fff2258a2376d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Simon=20Maria=20M=C3=B6llers?= Date: Thu, 6 Jul 2017 15:34:30 +0200 Subject: [PATCH] Generate an index.ts file for Aurelia #5987 --- .../TypeScriptAureliaClientCodegen.java | 1 + .../typescript-aurelia/index.ts.mustache | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 modules/swagger-codegen/src/main/resources/typescript-aurelia/index.ts.mustache diff --git a/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/TypeScriptAureliaClientCodegen.java b/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/TypeScriptAureliaClientCodegen.java index ef4316e5187..cb2d71c0338 100644 --- a/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/TypeScriptAureliaClientCodegen.java +++ b/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/TypeScriptAureliaClientCodegen.java @@ -44,6 +44,7 @@ public void processOpts() { // Set supporting files supportingFiles.add(new SupportingFile("models.mustache", "", "models.ts")); + supportingFiles.add(new SupportingFile("index.ts.mustache", "", "index.ts")); supportingFiles.add(new SupportingFile("Api.ts.mustache", "", "Api.ts")); supportingFiles.add(new SupportingFile("AuthStorage.ts.mustache", "", "AuthStorage.ts")); supportingFiles.add(new SupportingFile("git_push.sh.mustache", "", "git_push.sh")); diff --git a/modules/swagger-codegen/src/main/resources/typescript-aurelia/index.ts.mustache b/modules/swagger-codegen/src/main/resources/typescript-aurelia/index.ts.mustache new file mode 100644 index 00000000000..143e7b42f33 --- /dev/null +++ b/modules/swagger-codegen/src/main/resources/typescript-aurelia/index.ts.mustache @@ -0,0 +1,16 @@ +{{>licenseInfo}} +export { Api } from './Api'; +export { AuthStorage } from './AuthStorage'; +{{#apiInfo}} +{{#apis}} +{{#operations}} +export { {{classname}} } from './{{classname}}'; +{{/operations}} +{{/apis}} +{{/apiInfo}} +export { +{{#models}} +{{#model}} {{classname}}, +{{/model}} +{{/models}} +} from './models';