- Focus of this commit is to have modern gradle build. - Migrate most of a plugin configurations from dsl into buildSrc. - This fixes issues with existing docs build. - Allows to sign files so that we have that part done for central in a build. - We can skip publishing samples. - We're able to share similar logic for modules which are meant for publish or just being samples. - It's easier to upgrade gradle versions without getting various build issues. - Relates #1143
59 lines
1.7 KiB
Groovy
59 lines
1.7 KiB
Groovy
plugins {
|
|
id "java-gradle-plugin"
|
|
id "java"
|
|
}
|
|
|
|
sourceCompatibility = JavaVersion.VERSION_17;
|
|
|
|
repositories {
|
|
gradlePluginPortal()
|
|
mavenCentral()
|
|
maven { url 'https://repo.spring.io/plugins-release/' }
|
|
maven { url "https://repo.spring.io/snapshot" }
|
|
}
|
|
|
|
ext {
|
|
def propertiesFile = new File(new File("$projectDir").parentFile, "gradle.properties")
|
|
propertiesFile.withInputStream {
|
|
def properties = new Properties()
|
|
properties.load(it)
|
|
set("springBootVersion", properties["springBootVersion"])
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation(platform("org.springframework.boot:spring-boot-dependencies:${springBootVersion}"))
|
|
implementation("org.springframework:spring-core")
|
|
implementation 'org.asciidoctor:asciidoctor-gradle-jvm:3.3.2'
|
|
implementation 'org.jfrog.buildinfo:build-info-extractor-gradle:4.29.0'
|
|
}
|
|
|
|
gradlePlugin {
|
|
plugins {
|
|
modulePlugin {
|
|
id = "org.springframework.statemachine.module"
|
|
implementationClass = "org.springframework.statemachine.gradle.ModulePlugin"
|
|
}
|
|
starterPlugin {
|
|
id = "org.springframework.statemachine.starter"
|
|
implementationClass = "org.springframework.statemachine.gradle.StarterPlugin"
|
|
}
|
|
bomPlugin {
|
|
id = "org.springframework.statemachine.bom"
|
|
implementationClass = "org.springframework.statemachine.gradle.BomPlugin"
|
|
}
|
|
docsPlugin {
|
|
id = "org.springframework.statemachine.docs"
|
|
implementationClass = "org.springframework.statemachine.gradle.DocsPlugin"
|
|
}
|
|
distPlugin {
|
|
id = "org.springframework.statemachine.root"
|
|
implementationClass = "org.springframework.statemachine.gradle.RootPlugin"
|
|
}
|
|
samplePlugin {
|
|
id = "org.springframework.statemachine.sample"
|
|
implementationClass = "org.springframework.statemachine.gradle.SamplePlugin"
|
|
}
|
|
}
|
|
}
|