Paper/scripts/build.sh

16 lines
439 B
Bash
Raw Normal View History

2016-04-02 11:55:54 +08:00
#!/usr/bin/env bash
(
set -e
basedir="$(cd "$1" && pwd -P)"
gitcmd="git -c commit.gpgsign=false"
2016-04-02 11:55:54 +08:00
($gitcmd submodule update --init && ./scripts/remap.sh "$basedir" && ./scripts/decompile.sh "$basedir" && ./scripts/init.sh "$basedir" && ./scripts/applyPatches.sh "$basedir") || (
echo "Failed to build Paper"
exit 1
2016-04-02 11:55:54 +08:00
) || exit 1
if [ "$2" == "--jar" ]; then
mvn clean install && ./scripts/paperclip.sh "$basedir"
2016-04-02 11:55:54 +08:00
fi
) || exit 1