Removed GH API calls

This commit is contained in:
Anuken 2018-12-30 10:27:37 -05:00
parent 98e4f7409b
commit 745d8122f5

View File

@ -1,5 +1,3 @@
import groovy.json.JsonSlurper
buildscript{
repositories{
mavenLocal()
@ -38,8 +36,9 @@ allprojects{
//get latest commit hash from gtihub since JITPack's '-snapshot' version doesn't work correctly
if(arcHash == null){
try{
arcHash = new JsonSlurper().parse(new URL("https://api.github.com/repos/Anuken/Arc/commits/master"))["sha"]
arcHash = 'git ls-remote https://github.com/Anuken/Arc.git'.execute().text.split("\t")[0]//new JsonSlurper().parse(new URL("https://api.github.com/repos/Anuken/Arc/commits/master"))["sha"]
}catch(e){ //github can get angry sometimes
e.printStackTrace()
arcHash = "-SNAPSHOT";
}
}