Last change
on this file since 322 was
322,
checked in by hendrikvanantwerpen, 13 years ago
|
Added Play! framework and application with Jena dependency. Working on
the basic things now (login/register), after that start implementing
our data model.
|
-
Property svn:executable set to
*
|
File size:
1.2 KB
|
Rev | Line | |
---|
[322] | 1 | #! /usr/bin/env sh |
---|
| 2 | |
---|
| 3 | PRG="$0" |
---|
| 4 | while [ -h "$PRG" ] ; do |
---|
| 5 | PRG=`readlink "$PRG"` |
---|
| 6 | done |
---|
| 7 | dir=`dirname $PRG` |
---|
| 8 | |
---|
| 9 | if [ -f conf/application.conf ]; then |
---|
| 10 | if test "$1" = "clean-all"; then |
---|
| 11 | rm -rf target |
---|
| 12 | rm -rf tmp |
---|
| 13 | rm -rf logs |
---|
| 14 | rm -rf dist |
---|
| 15 | rm -rf project/project |
---|
| 16 | rm -rf project/target |
---|
| 17 | if [ $# -ne 1 ] |
---|
| 18 | then |
---|
| 19 | shift |
---|
| 20 | else |
---|
| 21 | echo "[info] Done!" |
---|
| 22 | exit 0 |
---|
| 23 | fi |
---|
| 24 | fi |
---|
| 25 | if test "$1" = "stop"; then |
---|
| 26 | if [ -f RUNNING_PID ]; then |
---|
| 27 | echo "[info] Stopping application (with PID `cat RUNNING_PID`)..." |
---|
| 28 | kill `cat RUNNING_PID` |
---|
| 29 | |
---|
| 30 | RESULT=$? |
---|
| 31 | |
---|
| 32 | if test "$RESULT" = 0; then |
---|
| 33 | echo "[info] Done!" |
---|
| 34 | exit 0 |
---|
| 35 | else |
---|
| 36 | echo "[\033[31merror\033[0m] Failed ($RESULT)" |
---|
| 37 | exit $RESULT |
---|
| 38 | fi |
---|
| 39 | else |
---|
| 40 | echo "[\033[31merror\033[0m] No RUNNING_PID file. Is this application running?" |
---|
| 41 | exit 1 |
---|
| 42 | fi |
---|
| 43 | fi |
---|
| 44 | |
---|
| 45 | if test "$1" = "debug"; then |
---|
| 46 | JPDA_PORT="9999" |
---|
| 47 | shift |
---|
| 48 | fi |
---|
| 49 | |
---|
| 50 | if [ -n "$1" ]; then |
---|
| 51 | JPDA_PORT="${JPDA_PORT}" $dir/framework/build "$@" |
---|
| 52 | else |
---|
| 53 | JPDA_PORT="${JPDA_PORT}" $dir/framework/build play |
---|
| 54 | fi |
---|
| 55 | |
---|
| 56 | else |
---|
| 57 | java -Dsbt.ivy.home=$dir/repository -Dplay.home=$dir/framework -Dsbt.boot.properties=$dir/framework/sbt/play.boot.properties -jar $dir/framework/sbt/sbt-launch.jar "$@" |
---|
| 58 | fi |
---|
Note: See
TracBrowser
for help on using the repository browser.