-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
89 lines (78 loc) · 1.98 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
plugins {
id 'java'
id 'maven-publish'
id "com.github.johnrengelman.shadow" version "8.1.1"
}
group = 'net.lapismc'
archivesBaseName = "LapisMine"
version = '0.1.0'
sourceCompatibility = '17'
targetCompatibility = '17'
defaultTasks 'clean', 'build', 'shadowJar'
repositories {
mavenCentral()
//Spigot repo
maven {
name = "spigotmc-repo"
url = "https://hub.spigotmc.org/nexus/content/repositories/snapshots/"
}
//Personal Repo
maven {
name = "lapismc-repo"
url = "https://maven.lapismc.net/repository/maven/"
}
//Pretty time
maven {
name = "sonatype"
url = "https://oss.sonatype.org/content/groups/public/"
}
//World Edit
maven {
name = "World Edit Repo"
url = "https://maven.enginehub.org/repo/"
}
//Paper
maven {
name = "PaperMC Repo"
url = uri("https://repo.papermc.io/repository/maven-public/")
}
}
dependencies {
implementation 'net.lapismc:LapisCore:1.12.18'
compileOnly "org.spigotmc:spigot-api:1.20.4-R0.1-SNAPSHOT"
compileOnly "com.sk89q.worldedit:worldedit-bukkit:7.2.9-SNAPSHOT"
}
shadowJar {
archiveFileName.set(archivesBaseName + ".jar")
exclude 'javax/**'
relocate("org.ocpsoft.prettytime", "net.lapismc.lapismine.util.prettytime")
relocate("net.lapismc.lapiscore", "net.lapismc.lapismine.util.core")
}
processResources {
filter {
it.replace('${project.version}', project.getVersion())
}
}
javadoc {
source = sourceSets.main.allJava
include("net/lapismc/lapismine/mines/*.java")
include("net/lapismc/lapismine/LapisMine.java")
}
task javadocJar(type: Jar) {
archiveClassifier.set('javadoc')
from javadoc
}
task sourcesJar(type: Jar) {
archiveClassifier.set('sources')
from sourceSets.main.allSource
}
artifacts {
archives javadocJar, sourcesJar, shadowJar
}
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
java {
withSourcesJar()
withJavadocJar()
}