lemo-crm/server/deploy
2017-07-15 10:08:04 +08:00

24 lines
537 B
Bash
Executable File

#!/bin/bash
# get real path of softlink
get_real_path() {
local f="$1"
while [ -h "$f" ]; do
ls=`ls -ld "$f"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
f="$link"
else
f=`dirname "$f"`/"$link"
fi
done
eval "$2"="'$f'"
}
get_real_path "$0" prg_path
echo "Script Path [$prg_path]"
PROJECT_HOME=$(dirname $prg_path)
echo "Project Home [$PROJECT_HOME]"
cd "$PROJECT_HOME"
mvn clean package -pl crm -am -DskipTests -Ptest