-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathbuild.gradle
More file actions
67 lines (59 loc) · 1.7 KB
/
build.gradle
File metadata and controls
67 lines (59 loc) · 1.7 KB
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
plugins {
id 'java'
id 'maven-publish'
id("io.papermc.paperweight.userdev") version "2.0.0-beta.14" // the latest version can be found on the Gradle Plugin Portal
}
// The Minecraft version we're currently building for
def minecraftVersion = '1.21.4'
// The Paper JavaDoc version to use
def javaDocVersion = '1.21.4'
// Where this builds on the server
def serverLocation = '1-21-4'
// Version of NMS-API
def projectVersion = '1.7.3'
compileJava {
sourceCompatibility = '21'
targetCompatibility = '21'
options.encoding = 'UTF-8'
}
repositories {
mavenCentral()
}
dependencies {
paperweight.paperDevBundle("${minecraftVersion}-R0.1-SNAPSHOT")
}
build {
project.version = "${projectVersion}-${minecraftVersion}"
dependsOn(reobfJar)
tasks.withType(JavaCompile).tap {
configureEach {
options.compilerArgs.add("-Xlint:unchecked")
options.compilerArgs.add("-Xlint:deprecation")
}
}
}
// Run task to build jar to another spot
tasks.register('server', Copy) {
from jar // Mapped jar
//from reobfJar // Obfuscated jar
// Change this to wherever you want your jar to build
into '/Users/ShaneBee/Desktop/Server/Skript/' + serverLocation + '/plugins/skript-reflect/'
}
publishing {
publications {
maven(MavenPublication) {
groupId 'com.github.ShaneBeee'
artifactId 'NMS-API'
version projectVersion
artifact jar
}
}
}
javadoc {
destinationDir = file("${projectDir}/build/javadoc")
options {
links("https://jd.papermc.io/paper/" + javaDocVersion)
title("NMS-API - ${projectVersion}")
}
exclude('com/shanebeestudios/nms/api/reflection')
}