Skip to content

Commit 3a8465e

Browse files
committed
Removed jabel, fixed deprecation warnings
1 parent 69089a1 commit 3a8465e

2 files changed

Lines changed: 9 additions & 30 deletions

File tree

build.gradle

Lines changed: 9 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -9,34 +9,26 @@ repositories{
99

1010
//Downloads the dependencies JAR file from Mindustry releases; does not use any real repository. Surprisingly, this is the most reliable option.
1111
ivy{
12-
url 'https://github.com/'
12+
url = 'https://github.com/'
1313
patternLayout{artifact '/[organisation]/[module]/releases/download/[revision]/dependencies.jar'}
1414
metadataSources{ artifact() }
1515
}
1616

1717
//"Latest" option to depend on BE builds.
1818
ivy{
19-
url 'https://github.com/'
19+
url = 'https://github.com/'
2020
patternLayout{artifact '/[organisation]/[module]/releases/download/master/[revision].jar'}
2121
metadataSources{ artifact() }
2222
}
23-
24-
//Do the same with jabel
25-
ivy{
26-
url 'https://github.com/'
27-
patternLayout{artifact '/[organisation]/[module]/releases/download/[revision]/jabel.jar'}
28-
metadataSources{ artifact() }
29-
}
3023
}
3124

3225
java{
33-
targetCompatibility = 8
26+
targetCompatibility = JavaVersion.VERSION_17
3427
sourceCompatibility = JavaVersion.VERSION_17
3528
}
3629

3730
ext{
3831
mindustryVersion = 'v158.1' //the build number that this mod is made for
39-
jabelVersion = "93fde537c7"
4032
isWindows = System.getProperty("os.name").toLowerCase().contains("windows")
4133
sdkRoot = System.getenv("ANDROID_HOME") ?: System.getenv("ANDROID_SDK_ROOT")
4234
}
@@ -54,12 +46,11 @@ dependencies{
5446
def useLatest = false //set to "true" to always depend on the newest version of mindustry
5547

5648
compileOnly useLatest ? "Anuken:MindustryBuilds:latest" : "Anuken:Mindustry:$mindustryVersion"
57-
58-
annotationProcessor "Anuken:jabel:v1.0.0"
5949
}
6050

6151
tasks.register('jarAndroid'){
6252
dependsOn "jar"
53+
def projectName = project.name
6354

6455
doLast{
6556
if(!sdkRoot || !new File(sdkRoot).exists()) throw new GradleException("No valid Android SDK found. Ensure that ANDROID_HOME is set to your Android SDK directory.")
@@ -74,7 +65,7 @@ tasks.register('jarAndroid'){
7465
def d8 = isWindows ? "d8.bat" : "d8"
7566

7667
//dex and desugar files - this requires d8 in your PATH
77-
"$d8 $dependencies --min-api 14 --output ${project.name}Android.jar ${project.name}Desktop.jar"
68+
"$d8 $dependencies --min-api 14 --output ${projectName}Android.jar ${projectName}Desktop.jar"
7869
.execute(null, new File("build/libs")).waitForProcessOutput(System.out, System.err)
7970
}
8071
}
@@ -96,15 +87,16 @@ jar{
9687
}
9788

9889
tasks.register('deploy', Jar){
90+
def projectName = project.name
9991
dependsOn jarAndroid
10092
dependsOn jar
101-
archiveFileName = "${project.name}.jar"
93+
archiveFileName = "${projectName}.jar"
10294

103-
from{ [zipTree("build/libs/${project.name}Desktop.jar"), zipTree("build/libs/${project.name}Android.jar")] }
95+
from{ [zipTree("build/libs/${projectName}Desktop.jar"), zipTree("build/libs/${projectName}Android.jar")] }
10496

10597
doLast{
10698
delete{
107-
delete "build/libs/${project.name}Android.jar"
99+
delete "build/libs/${projectName}Android.jar"
108100
}
109101
}
110102
}

gradle.properties

Lines changed: 0 additions & 13 deletions
This file was deleted.

0 commit comments

Comments
 (0)