-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.gradle
More file actions
114 lines (89 loc) · 2.75 KB
/
build.gradle
File metadata and controls
114 lines (89 loc) · 2.75 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
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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
import static fr.il_totore.manadrop.MinecraftDependencyHelper.paperApi
import static fr.il_totore.manadrop.MinecraftRepositoryHelper.*
plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm' version '1.4.20'
id 'fr.il_totore.manadrop' version '0.4.1-SNAPSHOT'
id 'maven-publish'
}
group 'net.royalsaga.minecraft'
version '0.0.1'
def GITHUB_ORG = 'RoyalSaga'
def GITHUB_REPO = project.name
repositories {
mavenCentral()
jcenter()
spigotSnapshot()
paperPublic()
sonatype()
maven {
url = 'https://repo.codemc.org/repository/maven-public/'
}
maven {
url = 'https://jitpack.io'
}
}
dependencies {
compileOnly 'org.jetbrains.kotlin:kotlin-stdlib'
compileOnly 'me.mattstudios.utils:matt-framework-gui:2.0.3'
//compileOnly 'com.github.MilkBowl:VaultAPI:1.7'
//compileOnly fileTree(include: ['*.jar'], dir: 'libs')
compileOnly paperApi('1.16.4')
}
compileJava.options.encoding = "UTF-8"
compileKotlin.kotlinOptions {
jvmTarget = JavaVersion.VERSION_11
javaParameters = true
}
task packageJavadoc(type: Jar, dependsOn: javadoc) {
archiveClassifier.set('javadoc')
}
javadoc {
options.encoding("UTF-8")
if (options instanceof StandardJavadocDocletOptions) {
def opt = options as StandardJavadocDocletOptions
opt.links(
"https://javadoc.io/doc/org.jetbrains/annotations/20.1.0/"
)
if (JavaVersion.current().isJava9Compatible()) {
opt.addBooleanOption("html5", true)
opt.addStringOption("-release", "8")
}
if (JavaVersion.current().isJava11Compatible()) {
opt.addBooleanOption("-no-module-directories", true)
}
}
}
task packageSources(type: Jar) {
archiveClassifier.set('sources')
from sourceSets.main.allSource
}
publishing {
publications {
mavenKotlin(MavenPublication) {
from components.kotlin
artifact packageSources
artifact packageJavadoc
pom {
url = "https://github.com/$GITHUB_ORG/$GITHUB_REPO"
scm {
connection = "scm:git:git://github.com/$GITHUB_ORG/${GITHUB_REPO}.git"
developerConnection = "scm:git:ssh://github.com:$GITHUB_ORG/${GITHUB_REPO}.git"
url = "http://github.com/$GITHUB_ORG/$GITHUB_REPO"
}
}
}
}
repositories {
/*
maven {
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/$GITHUB_ORG/$GITHUB_REPO")
credentials {
username = System.getenv("GITHUB_USERNAME")
password = System.getenv("GITHUB_PACKAGES_TOKEN")
}
}*/
mavenLocal()
}
}