#!/bin/bash function cleanup { if [[ ${PID:+x} ]]; then kill -9 $PID fi } trap cleanup EXIT if [ "%GNJ_INSTALLED" = "true" ]; then export CLASSPATH="%INSTALL_PATH/share/java/*" else DIR=`dirname $0` # if we are in the development environment use class files directly instead of jar export CLASSPATH="$DIR/../build-gradle/classes/main/:$DIR/../build-gradle/resources/main/:$DIR/../lib/*" fi java -ea org.gnunet.voting.TallyAuthorityDaemon "$@" & PID=$! wait $PID unset PID