From fb45d7340636fae7e9af666277d05cd10c40ce1a Mon Sep 17 00:00:00 2001 From: Leijurv Date: Wed, 26 Sep 2018 10:06:52 -0700 Subject: [PATCH] fetch jars from gradle instead of dropbox, fixes #189 --- .travis.yml | 2 -- Dockerfile | 1 + scripts/build.sh | 12 +++++++++--- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 72ffe2089..078433334 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,8 +6,6 @@ services: - docker install: -- sudo apt-get update -- sudo apt-get install jshon - docker build -t cabaletta/baritone . script: diff --git a/Dockerfile b/Dockerfile index a6d8d6868..39649e3a4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,6 +19,7 @@ ADD . /code RUN echo "\nrunClient {\nargs \"--width\",\"128\",\"--height\",\"128\"\n}" >> /code/build.gradle +# this .deb is specially patched to support lwjgl RUN dpkg -i /code/scripts/xvfb_1.16.4-1_amd64.deb WORKDIR /code diff --git a/scripts/build.sh b/scripts/build.sh index 21bd24f37..4c17a226c 100644 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -10,9 +10,15 @@ cat ../../scripts/proguard.pro | grep -v "this is the rt jar" | grep -v "\-injar echo "-libraryjars '$(java -verbose 2>/dev/null | sed -ne '1 s/\[Opened \(.*\)\]/\1/p')'" >> api.pro # insert correct rt.jar location tail api.pro # debug, print out what the previous two commands generated cat api.pro | grep -v "\-keep class baritone.api" > standalone.pro # standalone doesn't keep baritone api -wget -nv https://www.dropbox.com/s/zmc2l3jnwdvzvak/tempLibraries.zip?dl=1 # i'm sorry -mv tempLibraries.zip?dl=1 tempLibraries.zip -unzip tempLibraries.zip + +#wget -nv https://www.dropbox.com/s/zmc2l3jnwdvzvak/tempLibraries.zip?dl=1 # i'm sorry +#mv tempLibraries.zip?dl=1 tempLibraries.zip +#unzip tempLibraries.zip + +#instead of downloading these jars from my dropbox in a zip, just assume gradle's already got them for us +mkdir tempLibraries +cat proguard.pro | grep tempLibraries | grep .jar | cut -d "/" -f 2- | cut -d "'" -f -1 | xargs -n1 -I{} bash -c "find ~/.gradle -name {}" | tee /dev/stderr | xargs -n1 -I{} cp {} tempLibraries + mkdir ../../dist java -jar ../../proguard6.0.3/lib/proguard.jar @api.pro mv Obfuscated/baritone-$VERSION.jar ../../dist/baritone-api-$VERSION.jar