From dd492a732788a3f2b4b121301ff38c818ac34ccb Mon Sep 17 00:00:00 2001 From: Tobias Ottenweller Date: Sun, 19 May 2013 10:06:27 +0200 Subject: [PATCH] updated the test-deployment script. --- scripts/test-deployment.sh | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/scripts/test-deployment.sh b/scripts/test-deployment.sh index 24ec64c..73613d0 100755 --- a/scripts/test-deployment.sh +++ b/scripts/test-deployment.sh @@ -2,8 +2,17 @@ SCRIPT_DIR=$(dirname "$0") -BUKKIT_DIR="$SCRIPT_DIR/../bukkit-testserver" -PLUGIN_DIR="$SCRIPT_DIR/../bukkit-testserver/plugins" +DEVELOPER=$(whoami) + +if [ $DEVELOPER = "tobi" ]; then + BUKKIT_DIR="$HOME/minecraft/testbuk" + PLUGIN_DIR="$HOME/minecraft/testbuk/plugins" +else + BUKKIT_DIR="$SCRIPT_DIR/../bukkit-testserver" + PLUGIN_DIR="$SCRIPT_DIR/../bukkit-testserver/plugins" +fi + + # TODO: This is a bad solution! Maven should write necessary information into an extra file. ARTIFACT_ID="$(grep -C3 'de.craftinc' "$SCRIPT_DIR/../pom.xml" | grep '' | sed 's/[ \t]*//g' | sed 's/<\/artifactId>[ \t]*//g')" @@ -18,4 +27,9 @@ cp "$SCRIPT_DIR/../target/$ARTIFACT_ID-$VERSION".jar "$PLUGIN_DIR/$ARTIFACT_ID". echo -e "ddidderr\nmice_on_drugs\nMochaccino\nbeuth_el_max" > "$BUKKIT_DIR/ops.txt" -"$SCRIPT_DIR/minecraft.sh" reload_or_start + +if [ $DEVELOPER = "tobi" ]; then + "$BUKKIT_DIR/../minecraft.sh" reload_or_start +else + "$SCRIPT_DIR/minecraft.sh" reload_or_start +fi