#!/bin/sh # Modified by T.Nilsson, IRFU, 1 Nov 2013 export LD_LIBRARY_PATH=./dependencies/thirdparty/jre-1.6.0_22-linux64b/lib/amd64/xawt:$LD_LIBRARY_PATH NOW=`date +%s` while getopts ":p:b:hm" opt; do case $opt in p) ./dependencies/thirdparty/jre-1.6.0_22-linux64b/bin/java -Xmx10024M -jar -Dspis.timestamp=$NOW -Dlogback.configurationFile=resources/logging/logback-headless.xml -Dfelix.config.properties=file:resources/felix/config.properties -Dactivate3DViews=false -Dorg.keridwen.config=./resources/org-spis-geo-linux64b.properties -Dorg.keridwen.headless=true -Dorg.spis.batch.project.path=$OPTARG dependencies/thirdparty/felix-4.0.2/felix.jar exit 0 ;; b) ./dependencies/thirdparty/jre-1.6.0_22-linux64b/bin/java -Xmx10024M -jar -Dspis.timestamp=$NOW -Dlogback.configurationFile=resources/logging/logback-headless.xml -Dfelix.config.properties=file:resources/felix/config.properties -Dactivate3DViews=false -Dorg.keridwen.config=./resources/org-spis-geo-linux64b.properties -Dorg.keridwen.headless=true -Dorg.spis.batch.script.path=$OPTARG dependencies/thirdparty/felix-4.0.2/felix.jar exit 0 ;; h) echo "Usage:" echo "* To run SPIS with its graphical user interface:\n" echo "\n" echo "* To run SPIS in batch mode and execute a simulation from a given SPIS project:\n" echo "$0 -p path/to/project.spis5\n" echo "* To run SPIS in batch mode and execute a given Jython script:\n" echo "$0 -b path/to/jython/script\n" exit 2 ;; m) ./dependencies/thirdparty/jre-1.6.0_22-linux64b/bin/java -Xmx10024M -splash:resources/images/splash_spis-geo-png24.png -jar -Dspis.timestamp=$NOW -Dlogback.configurationFile=resources/logging/logback.xml -Dfelix.config.properties=file:resources/felix/config.properties -Dactivate3DViews=false -Dorg.keridwen.config=./resources/org-spis-geo-linux64b.properties -DforceLAF=Metal dependencies/thirdparty/felix-4.0.2/felix.jar exit 0 ;; ?) ./dependencies/thirdparty/jre-1.6.0_22-linux64b/bin/java -Xmx10024M -splash:resources/images/splash_spis-geo-png24.png -jar -Dspis.timestamp=$NOW -Dlogback.configurationFile=resources/logging/logback.xml -Dfelix.config.properties=file:resources/felix/config.properties -Dactivate3DViews=false -Dorg.keridwen.config=./resources/org-spis-geo-linux64b.properties dependencies/thirdparty/felix-4.0.2/felix.jar #echo "Invalid option: -$OPTARG" >&2 exit 0 ;; esac done # If no options or arguments where added, just start SPIS ./dependencies/thirdparty/jre-1.6.0_22-linux64b/bin/java -Xmx10024M -splash:resources/images/splash_spis-geo-png24.png -jar -Dspis.timestamp=$NOW -Dlogback.configurationFile=resources/logging/logback.xml -Dfelix.config. properties=file:resources/felix/config.properties -Dactivate3DViews=false -Dorg.keridwen.config=./resources/org-spis-geo-linux64b.properties dependencies/thirdparty/felix-4.0.2/felix.jar exit 0