Skip to content

Commit 2f01de4

Browse files
committed
build: use Kotlin DSL
1 parent b2329e1 commit 2f01de4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+911
-1005
lines changed

boot/build.gradle

Lines changed: 0 additions & 63 deletions
This file was deleted.

boot/build.gradle.kts

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
plugins {
2+
id("java")
3+
id("org.springframework.boot") version "3.5.0"
4+
id("io.spring.dependency-management") version "1.1.7"
5+
}
6+
7+
group = "io.github.reajason"
8+
version = rootProject.version
9+
10+
java {
11+
toolchain {
12+
languageVersion = JavaLanguageVersion.of(17)
13+
}
14+
}
15+
16+
tasks.processResources { filesMatching("**/application.yaml") { expand(project.properties) } }
17+
18+
configurations {
19+
compileOnly {
20+
extendsFrom(configurations.annotationProcessor.get())
21+
}
22+
}
23+
24+
dependencies {
25+
implementation(project(":generator")) {
26+
exclude(group = "org.apache.tomcat", module = "tomcat-catalina")
27+
exclude(group = "commons-logging", module = "commons-logging")
28+
}
29+
implementation(project(":deserialize")) {
30+
exclude(group = "commons-logging", module = "commons-logging")
31+
}
32+
implementation("org.springframework.boot:spring-boot-starter-thymeleaf")
33+
implementation("org.springframework.boot:spring-boot-starter-web") {
34+
exclude(group = "org.springframework.boot", module = "spring-boot-starter-tomcat")
35+
}
36+
implementation("org.apache.commons:commons-lang3:3.17.0")
37+
implementation("org.springframework.boot:spring-boot-starter-jetty")
38+
compileOnly("org.projectlombok:lombok")
39+
developmentOnly("org.springframework.boot:spring-boot-devtools")
40+
annotationProcessor("org.springframework.boot:spring-boot-configuration-processor")
41+
annotationProcessor("org.projectlombok:lombok")
42+
testImplementation("org.springframework.boot:spring-boot-starter-test")
43+
testRuntimeOnly("org.junit.platform:junit-platform-launcher")
44+
}
45+
46+
tasks.test {
47+
useJUnitPlatform()
48+
}

build.gradle

Lines changed: 0 additions & 117 deletions
This file was deleted.

build.gradle.kts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
plugins {
2+
id("java")
3+
}
4+
version = "1.10.0-SNAPSHOT"
5+
6+
tasks.register("publishAllToMavenCentral") {
7+
val isSnapshot = rootProject.version.toString().endsWith("-SNAPSHOT")
8+
if (isSnapshot) {
9+
dependsOn(":memshell-party-bom:publishAllPublicationsToMavenCentralRepository")
10+
dependsOn(":memshell-party-common:publishAllPublicationsToMavenCentralRepository")
11+
dependsOn(":deserialize:publishAllPublicationsToMavenCentralRepository")
12+
dependsOn(":memshell:publishAllPublicationsToMavenCentralRepository")
13+
dependsOn(":generator:publishAllPublicationsToMavenCentralRepository")
14+
} else {
15+
dependsOn(":memshell-party-bom:publishAndReleaseToMavenCentral")
16+
dependsOn(":memshell-party-common:publishAndReleaseToMavenCentral")
17+
dependsOn(":deserialize:publishAndReleaseToMavenCentral")
18+
dependsOn(":memshell:publishAndReleaseToMavenCentral")
19+
dependsOn(":generator:publishAndReleaseToMavenCentral")
20+
}
21+
}

buildSrc/build.gradle.kts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
plugins {
2+
`kotlin-dsl`
3+
}
4+
5+
repositories {
6+
mavenCentral()
7+
}
8+
9+
dependencies {
10+
implementation("com.vanniktech:gradle-maven-publish-plugin:0.32.0")
11+
}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
import com.vanniktech.maven.publish.SonatypeHost
2+
3+
plugins {
4+
id("com.vanniktech.maven.publish")
5+
}
6+
7+
mavenPublishing {
8+
publishToMavenCentral(SonatypeHost.CENTRAL_PORTAL)
9+
signAllPublications()
10+
coordinates(
11+
"io.github.reajason",
12+
project.name,
13+
rootProject.version as String
14+
)
15+
16+
pom {
17+
name.set("MemShellParty")
18+
description.set(project.description)
19+
url.set("https://github.com/ReaJason/MemShellParty")
20+
inceptionYear.set("2025")
21+
licenses {
22+
license {
23+
name.set("MIT")
24+
url.set("https://spdx.org/licenses/MIT.html")
25+
}
26+
}
27+
developers {
28+
developer {
29+
id.set("reajason")
30+
name.set("ReaJason")
31+
url.set("https://reajason.eu.org")
32+
}
33+
}
34+
scm {
35+
connection.set("scm:git:https://github.com/ReaJason/MemShellParty.git")
36+
developerConnection.set("scm:git:ssh://github.com/ReaJason/MemShellParty.git")
37+
url.set("https://github.com/ReaJason/MemShellParty")
38+
}
39+
}
40+
}

deserialize/build.gradle

Lines changed: 0 additions & 28 deletions
This file was deleted.

deserialize/build.gradle.kts

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
plugins {
2+
id("java")
3+
alias(libs.plugins.lombok)
4+
id("maven-publish-convention")
5+
}
6+
7+
group = "io.github.reajason"
8+
description = "Java deserialize payload for MemShellParty"
9+
version = rootProject.version
10+
11+
dependencies {
12+
implementation(platform(project(":memshell-party-bom")))
13+
implementation(project(":memshell-party-common"))
14+
implementation("net.bytebuddy:byte-buddy")
15+
implementation("com.caucho:hessian:4.0.66")
16+
implementation("commons-beanutils:commons-beanutils:1.9.2")
17+
implementation("commons-collections:commons-collections:3.2.1")
18+
implementation("org.apache.commons:commons-collections4:4.0")
19+
testImplementation(platform("org.junit:junit-bom"))
20+
testImplementation("org.junit.jupiter:junit-jupiter")
21+
}
22+
23+
java {
24+
toolchain {
25+
languageVersion = JavaLanguageVersion.of(8)
26+
}
27+
sourceCompatibility = JavaVersion.VERSION_1_8
28+
targetCompatibility = JavaVersion.VERSION_1_8
29+
}
30+
31+
tasks.test {
32+
useJUnitPlatform()
33+
}

0 commit comments

Comments
 (0)