diff -r 6fceb66e1ad7 -r 41d6c0cac8b3 helpers/sonews --- a/helpers/sonews Fri Jun 26 16:48:50 2009 +0200 +++ b/helpers/sonews Thu Oct 13 03:09:22 2011 +0200 @@ -1,6 +1,7 @@ #!/bin/bash CLASSPATH=/usr/share/java/sonews.jar:\ +/usr/share/java/sonews-helpers.jar:\ /usr/share/java/mysql-connector-java.jar:\ /usr/share/java/glassfish-mail.jar:\ /usr/share/java/postgresql.jar @@ -9,7 +10,7 @@ PIDFILE=/var/run/sonews.pid ARGS="-mlgw -c /etc/sonews/sonews.conf -feed" -MAINCLASS=org.sonews.daemon.Main +MAINCLASS=org.sonews.Main JAVA=java case "$1" in @@ -31,12 +32,18 @@ done echo "done." ;; + restart) + $0 stop && $0 start + ;; setup) $JAVA -classpath $CLASSPATH org.sonews.util.DatabaseSetup ;; purge) $JAVA -classpath $CLASSPATH org.sonews.util.Purger ;; + version) + $JAVA -classpath $CLASSPATH $MAINCLASS -version + ;; *) echo "Usage: sonews [start|stop|restart|setup|purge]" esac