forked from SmylerMC/terramap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
94 lines (79 loc) · 2.85 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
buildscript {
repositories {
jcenter()
maven { url = "https://files.minecraftforge.net/maven" }
}
dependencies {
classpath 'net.minecraftforge.gradle:ForgeGradle:2.3-SNAPSHOT'
}
}
apply plugin: 'net.minecraftforge.gradle.forge'
//Only edit below this line, the above code adds and enables the necessary things for Forge to be setup.
version = project.mod_version
group = project.mod_group
archivesBaseName = project.mod_id
sourceCompatibility = targetCompatibility = '1.8' // Need this here so eclipse task generates correctly.
// A note on the jdk version:
// Gradle seems to have issues with the latests versions of OpenJDK on Linux.
// If you experience errors related to LWJGL when launching the game in a developpement environement,
// make sure you are using at most the 18.8_232 jdk, if not, you can download it and set it at the jdk in your IDE's run build path section
compileJava {
sourceCompatibility = targetCompatibility = '1.8'
}
minecraft {
version = project.forge_version
mappings = project.mcp_mappings
runDir = "run"
}
repositories {
maven {
name = "JitPack"
url = "https://jitpack.io/"
}
maven { //used for leveldb
name = "DaPorkchop_"
url = "https://maven.daporkchop.net/"
}
maven { //used for leveldb
name = "OpenCollab Snapshots"
url = "https://repo.opencollab.dev/snapshot/"
}
}
dependencies {
deobfProvided ("com.github.OpenCubicChunks.CubicChunks:cubicchunks:6e18a97abe31e1c7892ebcf8ed0f17a4ac379e10") {
transitive = false
}
deobfProvided ("com.github.OpenCubicChunks:CubicWorldGen:27de56d2f792513873584b2f8fd9f3082fb259ec") {
transitive = false
}
deobfProvided ("com.github.BuildTheEarth:terraplusplus:8207d314bac2e7681d4211b658eb3f26d3f18f1a") {
transitive = true
}
runtime "org.apache.commons:commons-imaging:1.0-alpha2"
runtime("net.daporkchop:leveldb-mcpe-jni:0.0.10-SNAPSHOT") {
exclude group: "io.netty"
}
testCompile "junit:junit:4.12"
}
processResources {
// this will ensure that this task is redone when the versions change.
inputs.property "version", project.version
inputs.property "mcversion", project.minecraft.version
// replace stuff in mcmod.info, nothing else
from(sourceSets.main.resources.srcDirs) {
include 'mcmod.info'
// replace version and mcversion
expand 'version':project.version, 'mcversion':project.minecraft.version
}
// copy everything else except the mcmod.info
from(sourceSets.main.resources.srcDirs) {
exclude 'mcmod.info'
}
}
task deobfJar(type: Jar, dependsOn: 'jar') {
from "build/source/main"
classifier "dev"
}
artifacts {
archives deobfJar
}