-
Notifications
You must be signed in to change notification settings - Fork 6
/
build.gradle
81 lines (64 loc) · 2.06 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
import java.text.SimpleDateFormat
plugins {
id 'java'
id 'org.jetbrains.intellij' version '1.9.0'
id 'org.jetbrains.changelog' version '1.3.1'
}
group 'moe.knox.factorio'
version '1.4.0-PRERELEASE'
sourceCompatibility = JavaVersion.VERSION_17
repositories {
mavenCentral()
maven {
url = uri("https://jitpack.io")
}
}
dependencies {
implementation 'org.jsoup:jsoup:1.15.3'
testImplementation 'org.junit.jupiter:junit-jupiter:5.9.0'
testImplementation 'org.junit.jupiter:junit-jupiter-params:5.9.0'
testRuntimeOnly("org.junit.platform:junit-platform-launcher") {
because("Only needed to run tests in a version of IntelliJ IDEA that bundles older versions")
}
implementation 'com.github.Marcono1234:gson-record-type-adapter-factory:v0.2.0'
}
ext.getPluginChangelog = { ->
StringBuilder changelogHtml = new StringBuilder()
for (item in changelog.getAll().values()) {
if (item.isUnreleased) {
continue
}
changelogHtml.append("<h3>" + item.version + "</h3>\n")
changelogHtml.append("<ul>")
for (section in item.getSections()) {
String changesType = section.getKey()
for ( sectionItem in section.getValue() ) {
changelogHtml.append("<li>[" + changesType + "] " + sectionItem.substring(2) + "</li>\n")
}
}
changelogHtml.append("</ul>\n")
}
return changelogHtml.toString()
}
changelog {
path = "${project.projectDir}/Changelog.md"
header = "[${-> version.get()}] - ${new SimpleDateFormat("dd.MM.yyyy").format(new Date())}"
}
// See https://github.com/JetBrains/gradle-intellij-plugin/
intellij {
version = "2022.2"
plugins = [
"com.tang:1.3.7.2-IDEA222"
]
}
patchPluginXml {
changeNotes = getPluginChangelog()
sinceBuild = "222"
untilBuild = "222.*"
version = project.version
}
test {
useJUnitPlatform()
systemProperty("junit.jupiter.execution.parallel.enabled", true)
systemProperty("junit.jupiter.execution.parallel.mode.default", "concurrent")
}