-
Notifications
You must be signed in to change notification settings - Fork 43
/
build.gradle
97 lines (84 loc) · 3.81 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
apply plugin: 'kotlin'
apply plugin: 'java-library'
apply plugin: 'application'
apply plugin: 'org.jlleitschuh.gradle.ktlint'
buildscript {
repositories {
mavenCentral()
mavenLocal()
gradlePluginPortal()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
classpath "org.jlleitschuh.gradle:ktlint-gradle:11.5.0"
}
}
version = "1.12.1.10-SNAPSHOT"
mainClassName = 'gdx.liftoff.MainKt'
java.sourceCompatibility = JavaVersion.VERSION_1_8
java.targetCompatibility = JavaVersion.VERSION_1_8
kotlin.compilerOptions.jvmTarget.set(JvmTarget.JVM_1_8)
jar {
manifest {
attributes 'Main-Class': mainClassName
}
duplicatesStrategy(DuplicatesStrategy.EXCLUDE)
from { configurations.compileClasspath.collect { it.isDirectory() ? it : zipTree(it) } }
exclude('META-INF/INDEX.LIST', 'META-INF/*.SF', 'META-INF/*.DSA', 'META-INF/*.RSA')
dependencies {
exclude('META-INF/INDEX.LIST', 'META-INF/maven/**')
}
doLast {
file(archiveFile).setExecutable(true, false)
}
}
repositories {
mavenCentral()
maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }
maven { url "https://s01.oss.sonatype.org/content/repositories/snapshots/" }
maven { url "https://s01.oss.sonatype.org" }
maven { url 'https://jitpack.io' }
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlinVersion"
implementation "org.apache.commons:commons-exec:$commonsExecVersion"
implementation "com.badlogicgames.gdx:gdx:$gdxVersion"
implementation ("com.badlogicgames.gdx:gdx-backend-lwjgl3:$gdxVersion"){
exclude group: "org.jcraft", module: "jorbis"
exclude group: "org.lwjgl", module: "lwjgl-openal"
}
implementation "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
implementation "com.crashinvaders.lml:gdx-kiwi:$lmlVersion"
implementation "com.crashinvaders.lml:gdx-lml:$lmlVersion"
implementation "com.crashinvaders.lml:gdx-lml-vis:$lmlVersion"
implementation "com.crashinvaders.lml:gdx-autumn:$lmlVersion"
implementation "com.crashinvaders.lml:gdx-autumn-mvc:$lmlVersion"
implementation "com.crashinvaders.lml:gdx-autumn-desktop-fcs:$lmlVersion"
implementation "com.kotcrab.vis:vis-ui:$visUiVersion"
implementation "org.lwjgl:lwjgl-nfd:$nfdVersion"
implementation "org.lwjgl:lwjgl-nfd:$nfdVersion:natives-windows"
implementation "org.lwjgl:lwjgl-nfd:$nfdVersion:natives-windows-x86"
implementation "org.lwjgl:lwjgl-nfd:$nfdVersion:natives-linux"
implementation "org.lwjgl:lwjgl-nfd:$nfdVersion:natives-macos"
implementation "org.lwjgl:lwjgl-nfd:$nfdVersion:natives-macos-arm64"
// necessary because the current gdx-autumn-desktop-fcs has an implementation dep on this, and we need it here.
implementation "io.github.lukehutch:fast-classpath-scanner:2.21"
// for some network requests, such as checking the versions of dependencies
implementation "com.github.kittinunf.fuel:fuel:2.3.1"
// specifically for getting the latest stable versions from https://mvnrepository.com
// this was just updated, but this version has 4 vulnerable dependencies: okhttp, okio, retrofit, and jsoup
// implementation "com.github.devcsrj:mvnrepository-api-client:2.0.2"
// this is about the same code, but does not have any of the above vulnerable dependency versions
implementation 'com.github.tommyettinger:mvnrepository-client:v2.0.2.4'
implementation "org.slf4j:slf4j-nop:2.0.5"
implementation "com.github.tommyettinger:iconizer-gdx:$iconizerVersion"
}
tasks.register('sample', JavaExec) {
dependsOn classes
setDescription("Generates a sample libGDX project into build/dist/sample")
mainClass.set("gdx.liftoff.Sample")
setClasspath(sourceSets.main.runtimeClasspath)
}
jar.dependsOn('ktlintFormat')