gradle: вынесена общая логика gradle-modules
This commit is contained in:
33
build.gradle
Normal file
33
build.gradle
Normal file
@@ -0,0 +1,33 @@
|
||||
import libs.LibsPlugin
|
||||
|
||||
subprojects {
|
||||
apply plugin: 'java'
|
||||
apply plugin: LibsPlugin
|
||||
apply plugin: LogicPlugin
|
||||
|
||||
def publishScript = rootDir.toPath().resolve('publish.gradle').toFile()
|
||||
if (publishScript.exists()) {
|
||||
apply from: publishScript
|
||||
}
|
||||
|
||||
project.group = projectGroup
|
||||
project.version = moduleVersion
|
||||
jar.archiveBaseName.set(moduleName)
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly libs.lombok
|
||||
annotationProcessor libs.lombok
|
||||
|
||||
testImplementation libs.test.junit5
|
||||
testImplementation libs.test.mock
|
||||
}
|
||||
|
||||
test {
|
||||
useJUnitPlatform()
|
||||
}
|
||||
}
|
||||
@@ -1,42 +1,13 @@
|
||||
import libs.LibsPlugin
|
||||
|
||||
plugins {
|
||||
id 'java'
|
||||
}
|
||||
|
||||
apply plugin: LibsPlugin
|
||||
apply plugin: LogicPlugin
|
||||
|
||||
def publishScript = file(rootProject.getProjectDir().getPath() + '/publish.gradle')
|
||||
if (publishScript.exists()) {
|
||||
apply from: publishScript.path
|
||||
}
|
||||
|
||||
project.group = projectGroup
|
||||
project.version = moduleVersion
|
||||
jar.archiveBaseName.set(moduleName)
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
mavenCentral()
|
||||
maven repos.mavenSpigotMC
|
||||
maven repos.mavenDmxMcProject
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly libs.lombok
|
||||
annotationProcessor libs.lombok
|
||||
|
||||
compileOnly libs.bukkit
|
||||
implementation libs.commons_text
|
||||
implementation libs.refobj
|
||||
|
||||
testImplementation libs.test.junit5
|
||||
testImplementation libs.test.mock
|
||||
testImplementation libs.bukkit
|
||||
testImplementation libs.test.h2db
|
||||
}
|
||||
|
||||
test {
|
||||
useJUnitPlatform()
|
||||
}
|
||||
Reference in New Issue
Block a user