Skip to content

Commit

Permalink
update groovy with oas3 petstore, no diff (#205)
Browse files Browse the repository at this point in the history
  • Loading branch information
wing328 committed Apr 23, 2018
1 parent 6983dcf commit 450cbb8
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions bin/openapi3/groovy-petstore.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#!/bin/sh

SCRIPT="$0"
echo "# START SCRIPT: $SCRIPT"

while [ -h "$SCRIPT" ] ; do
ls=`ls -ld "$SCRIPT"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
SCRIPT="$link"
else
SCRIPT=`dirname "$SCRIPT"`/"$link"
fi
done

if [ ! -d "${APP_DIR}" ]; then
APP_DIR=`dirname "$SCRIPT"`/..
APP_DIR=`cd "${APP_DIR}"; pwd`
fi

executable="./modules/openapi-generator-cli/target/openapi-generator-cli.jar"

if [ ! -f "$executable" ]
then
mvn clean package
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 -i modules/openapi-generator/src/test/resources/3_0/petstore.yaml -l groovy -o samples/client/petstore/groovy -DhideGenerationTimestamp=true"
java $JAVA_OPTS -jar $executable $ags

0 comments on commit 450cbb8

Please sign in to comment.