updated scripts

This commit is contained in:
Tony Tam 2014-08-27 01:09:28 -07:00
parent d1603ba25e
commit dbf04a9563
2 changed files with 4 additions and 4 deletions

View File

@ -22,7 +22,7 @@ cd $APP_DIR
# if you've executed sbt assembly previously it will use that instead. # if you've executed sbt assembly previously it will use that instead.
export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DfileMap=src/test/resources/petstore-1.1/resources.json -DloggerPath=conf/log4j.properties" export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DfileMap=src/test/resources/petstore-1.2/api-docs -DloggerPath=conf/log4j.properties"
ags="$@ samples/client/petstore/java/JavaPetstoreCodegen.scala http://petstore.swagger.wordnik.com/api/api-docs special-key" ags="$@ samples/client/petstore/java/JavaPetstoreCodegen.scala http://petstore.swagger.wordnik.com/api/api-docs special-key"
if [ -f $APP_DIR/target/scala-$SCALA_RUNNER_VERSION/*assembly*.jar ]; then if [ -f $APP_DIR/target/scala-$SCALA_RUNNER_VERSION/*assembly*.jar ]; then

View File

@ -1,6 +1,7 @@
#!/bin/sh #!/bin/sh
SCRIPT="$0" SCRIPT="$0"
SCALA_RUNNER_VERSION=$(scala ./bin/Version.scala)
while [ -h "$SCRIPT" ] ; do while [ -h "$SCRIPT" ] ; do
ls=`ls -ld "$SCRIPT"` ls=`ls -ld "$SCRIPT"`
@ -18,15 +19,14 @@ if [ ! -d "${APP_DIR}" ]; then
fi fi
cd $APP_DIR cd $APP_DIR
SCALA_RUNNER_VERSION=$(scala ./bin/Version.scala)
# if you've executed sbt assembly previously it will use that instead. # 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" export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties"
ags="$@ samples/client/petstore/java/JavaPetstoreCodegen.scala http://petstore.swagger.wordnik.com/api/api-docs special-key" ags="$@ samples/client/petstore/java/JavaPetstoreCodegen.scala http://petstore.swagger.wordnik.com/api/api-docs special-key"
if [ -f $APP_DIR/target/scala-$SCALA_RUNNER_VERSION/*assembly*assembly*.jar ]; then if [ -f $APP_DIR/target/scala-$SCALA_RUNNER_VERSION/*assembly*.jar ]; then
scala -cp $APP_DIR/target/scala-$SCALA_RUNNER_VERSION/*assembly*assembly*.jar $ags scala -cp $APP_DIR/target/scala-$SCALA_RUNNER_VERSION/*assembly*.jar $ags
else else
echo "Please set scalaVersion := \"$SCALA_RUNNER_VERSION\" in build.sbt and run ./sbt assembly" echo "Please set scalaVersion := \"$SCALA_RUNNER_VERSION\" in build.sbt and run ./sbt assembly"
fi fi