From ddf9db3148a77d0807d4eedad19110513e4f82e8 Mon Sep 17 00:00:00 2001 From: wing328 Date: Fri, 14 Jul 2017 17:45:56 +0800 Subject: [PATCH] fix window batch scripts after ts angular generator rename --- bin/security/typescript-angular2.sh | 2 +- bin/windows/typescript-angular2-all.bat | 18 ------------------ bin/windows/typescript-angular2-with-npm.bat | 2 +- bin/windows/typescript-angular2.bat | 2 +- bin/windows/typescript-angular4-with-npm.bat | 10 ++++++++++ 5 files changed, 13 insertions(+), 21 deletions(-) delete mode 100644 bin/windows/typescript-angular2-all.bat create mode 100644 bin/windows/typescript-angular4-with-npm.bat diff --git a/bin/security/typescript-angular2.sh b/bin/security/typescript-angular2.sh index cdf5b44b6957..4bb954bae852 100755 --- a/bin/security/typescript-angular2.sh +++ b/bin/security/typescript-angular2.sh @@ -26,6 +26,6 @@ fi # if you've executed sbt assembly previously it will use that instead. export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties" -ags="$@ generate -t modules/swagger-codegen/src/main/resources/typescript-angular2 -i modules/swagger-codegen/src/test/resources/2_0/petstore-security-test.yaml -l typescript-angular2 -o samples/client/petstore-security-test/typescript-angular2" +ags="$@ generate -t modules/swagger-codegen/src/main/resources/typescript-angular2 -i modules/swagger-codegen/src/test/resources/2_0/petstore-security-test.yaml -l typescript-angular -o samples/client/petstore-security-test/typescript-angular2" java $JAVA_OPTS -jar $executable $ags diff --git a/bin/windows/typescript-angular2-all.bat b/bin/windows/typescript-angular2-all.bat deleted file mode 100644 index 119de7e7bcc3..000000000000 --- a/bin/windows/typescript-angular2-all.bat +++ /dev/null @@ -1,18 +0,0 @@ -set executable=.\modules\swagger-codegen-cli\target\swagger-codegen-cli.jar - -If Not Exist %executable% ( - mvn clean package -) - -REM set JAVA_OPTS=%JAVA_OPTS% -Xmx1024M -echo "Typescript Petstore API client (default)" -set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -l typescript-angular2 -o samples\client\petstore\typescript-angular2\default -java %JAVA_OPTS% -jar %executable% %ags% - -echo "Typescript Petstore API client (with interfaces generated)" -set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -l typescript-angular2 -o samples\client\petstore\typescript-angular2\with-interfaces -D withInterfaces=true -java %JAVA_OPTS% -jar %executable% %ags% - -echo "Typescript Petstore API client (npm setting)" -set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -l typescript-angular2 -c bin\typescript-petstore-npm.json -o samples\client\petstore\typescript-angular2\npm -java %JAVA_OPTS% -jar %executable% %ags% diff --git a/bin/windows/typescript-angular2-with-npm.bat b/bin/windows/typescript-angular2-with-npm.bat index 1882e6069d4a..0125441fac31 100644 --- a/bin/windows/typescript-angular2-with-npm.bat +++ b/bin/windows/typescript-angular2-with-npm.bat @@ -5,6 +5,6 @@ If Not Exist %executable% ( ) REM set JAVA_OPTS=%JAVA_OPTS% -Xmx1024M -set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -c bin\typescript-petstore-npm.json -l typescript-angular -o samples\client\petstore\typescript-angular2\npm +set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -c bin\typescript-petstore-npm.json -l typescript-angular -o samples\client\petstore\typescript-angular2\npm --additional-properties ngVersion=2 java %JAVA_OPTS% -jar %executable% %ags% diff --git a/bin/windows/typescript-angular2.bat b/bin/windows/typescript-angular2.bat index 9df7ca1d3283..b94528ba6d57 100755 --- a/bin/windows/typescript-angular2.bat +++ b/bin/windows/typescript-angular2.bat @@ -5,6 +5,6 @@ If Not Exist %executable% ( ) REM set JAVA_OPTS=%JAVA_OPTS% -Xmx1024M -set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -l typescript-angular -o samples\client\petstore\typescript-angular2\default +set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -l typescript-angular -o samples\client\petstore\typescript-angular2\default --additional-properties ngVersion=2 java %JAVA_OPTS% -jar %executable% %ags% diff --git a/bin/windows/typescript-angular4-with-npm.bat b/bin/windows/typescript-angular4-with-npm.bat new file mode 100644 index 000000000000..f91d22dca41b --- /dev/null +++ b/bin/windows/typescript-angular4-with-npm.bat @@ -0,0 +1,10 @@ +set executable=.\modules\swagger-codegen-cli\target\swagger-codegen-cli.jar + +If Not Exist %executable% ( + mvn clean package +) + +REM set JAVA_OPTS=%JAVA_OPTS% -Xmx1024M +set ags=generate -i modules\swagger-codegen\src\test\resources\2_0\petstore.yaml -c bin\typescript-petstore-npm.json -l typescript-angular -o samples\client\petstore\typescript-angular2\npm --additional-properties ngVersion=4 + +java %JAVA_OPTS% -jar %executable% %ags%