#!/usr/bin/env bash

echo "Downloading dependencies with no maven repository available"

wget https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar -O BuildTools.jar && java -jar BuildTools.jar --rev 1.13.1

wget https://www.robindebaets.be/LeaderHeadsAPI.jar && mvn install:install-file -Dfile=LeaderHeadsAPI.jar -DgroupId=me.robin -DartifactId=leaderheads -Dversion=3.1.6 -Dpackaging=jar

git clone https://github.com/Gnat008/perworldinventory-kt.git && cd perworldinventory-kt && mvn clean install

cd ../

git clone https://github.com/I-Al-Istannen/MiniNBT.git && cd MiniNBT && mvn clean install
#!/usr/bin/env bash

echo "Downloading dependencies with no maven repository available"

wget https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar -O BuildTools.jar && java -jar BuildTools.jar --rev 1.13.1

wget https://www.robindebaets.be/LeaderHeadsAPI.jar && mvn install:install-file -Dfile=LeaderHeadsAPI.jar -DgroupId=me.robin -DartifactId=leaderheads -Dversion=3.1.6 -Dpackaging=jar

jdk_switcher use openjdk8

git clone https://github.com/Gnat008/perworldinventory-kt.git && cd perworldinventory-kt && mvn clean install
cd ../

jdk_switcher use openjdk11

git clone https://github.com/I-Al-Istannen/MiniNBT.git && cd MiniNBT && mvn clean install
Make Travis switch back to Java 8 for perworldinventory-kt
Make Travis switch back to Java 8 for perworldinventory-kt

Building seems to fail on Java 11, Java 8 seems to work fine.
