-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use working directory for petep.json file, add WORKING_DIR param to s…
…h/bat files, minor fixes and refactors
- Loading branch information
Showing
18 changed files
with
320 additions
and
153 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,22 @@ | ||
#!/bin/bash | ||
|
||
# Useful params, change if needed | ||
JAVA="java" | ||
APP_HOME="`pwd`" | ||
APP_HOME=$(cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd) | ||
WORKING_DIR=$APP_HOME | ||
DEFAULT_JVM_OPTS= | ||
CMD_LINE_ARGS=$@ | ||
CLASSPATH=$APP_HOME/lib/* | ||
MAIN_CLASS="com.warxim.petep.Main" | ||
LOG_FILE=petep.log | ||
|
||
# Set working directory (important for petep.json), by default the startup directory is used | ||
cd $WORKING_DIR | ||
|
||
# Run PETEP | ||
if [[ $2 == '--nogui' ]]; | ||
then | ||
$JAVA -cp "$CLASSPATH" $MAIN_CLASS $CMD_LINE_ARGS | ||
$JAVA $DEFAULT_JVM_OPTS -cp "$CLASSPATH" $MAIN_CLASS $CMD_LINE_ARGS | ||
else | ||
nohup $JAVA -cp "$CLASSPATH" $MAIN_CLASS $CMD_LINE_ARGS > $LOG_FILE & | ||
fi | ||
nohup $JAVA $DEFAULT_JVM_OPTS -cp "$CLASSPATH" $MAIN_CLASS $CMD_LINE_ARGS > $LOG_FILE & | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.