-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
128 lines (113 loc) · 3.83 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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
buildscript {
apply from: file('commons/versions.gradle')
repositories {
mavenCentral()
jcenter()
maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokka_version"
classpath "gradle.plugin.com.hierynomus.gradle.plugins:license-gradle-plugin:$license_version"
classpath "com.github.jengelman.gradle.plugins:shadow:$shadow_version"
classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version"
}
}
group 'com.koresframework'
version '4.2.16.bytecode'
apply from: file("commons/common.gradle")
// Publish
apply plugin: 'maven-publish'
repositories {
mavenCentral()
maven {
name = "JGang"
url "https://gitlab.com/api/v4/projects/30392813/packages/maven"
}
}
dependencies {
implementation "com.koresframework:kores:4.2.16.base"
implementation 'com.github.jonathanxd:bytecode-disassembler:2.4.2'
implementation "org.ow2.asm:asm:9.2"
implementation "org.ow2.asm:asm-analysis:9.2"
implementation "org.ow2.asm:asm-tree:9.2"
implementation "org.ow2.asm:asm-util:9.2"
testImplementation "com.github.jonathanxd:links:$iutils_version"
testImplementation "com.koresframework:kores-test:4.2.16.base"
}
tasks.dokkaGfm.configure {
enabled = false
}
allprojects {
tasks.whenTaskAdded { task ->
if (task.name.contains("dokkaGfm")) {
task.enabled = false
}
}
}
shadowJar {
dependencies {
include(dependency("org.ow2.asm:asm-all"))
include(dependency("com.koresframework:kores:4.2.4.base"))
include(dependency("com.github.jonathanxd:bytecode-disassembler"))
include(dependency("com.github.jonathanxd:jwiutils"))
}
}
publishing {
repositories {
maven {
name = "Local"
// change to point to your repo, e.g. http://my.org/repo
url = "$buildDir/repo"
}
maven {
name = "GitHubPackages"
url = "https://maven.pkg.github.com/koresframework/kores-bytecodewriter"
credentials {
username = System.getenv("USERNAME")
password = System.getenv("TOKEN")
}
}
maven {
name = "GitLab"
url "https://gitlab.com/api/v4/projects/28905266/packages/maven"
credentials(HttpHeaderCredentials) {
def ciToken = System.getenv("CI_JOB_TOKEN")
if (ciToken != null && !ciToken.isEmpty()) {
name = "Job-Token"
value = System.getenv("CI_JOB_TOKEN")
} else {
name = "Private-Token"
value = project.findProperty("GITLAB_TOKEN") ?: System.getenv("GITLAB_TOKEN")
}
}
authentication {
header(HttpHeaderAuthentication)
}
}
maven {
name = "GitLabJgang"
url "https://gitlab.com/api/v4/projects/30392813/packages/maven"
credentials(HttpHeaderCredentials) {
def ciToken = System.getenv("CI_JOB_TOKEN")
if (ciToken != null && !ciToken.isEmpty()) {
name = "Job-Token"
value = System.getenv("CI_JOB_TOKEN")
} else {
name = "Private-Token"
value = project.findProperty("GITLAB_TOKEN") ?: System.getenv("GITLAB_TOKEN")
}
}
authentication {
header(HttpHeaderAuthentication)
}
}
}
publications {
maven(MavenPublication) {
artifactId 'kores-bytecodewriter'
from components.kotlin
artifact sourcesJar
}
}
}