2020-08-28 23:07:24 +02:00
|
|
|
plugins {
|
|
|
|
|
id 'java'
|
|
|
|
|
id 'application'
|
|
|
|
|
}
|
|
|
|
|
|
2020-11-10 18:36:02 +01:00
|
|
|
// ------------------------------------
|
|
|
|
|
// Hal common configuration
|
|
|
|
|
// ------------------------------------
|
2020-08-28 23:07:24 +02:00
|
|
|
|
2020-11-10 18:36:02 +01:00
|
|
|
allprojects {
|
2020-08-28 23:07:24 +02:00
|
|
|
repositories {
|
|
|
|
|
mavenLocal()
|
|
|
|
|
mavenCentral()
|
|
|
|
|
}
|
2020-11-10 18:36:02 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
subprojects {
|
|
|
|
|
apply plugin: 'java-library'
|
2020-08-28 23:07:24 +02:00
|
|
|
|
|
|
|
|
dependencies {
|
2021-09-10 22:19:02 +02:00
|
|
|
implementation 'se.koc:zutil:1.0.306'
|
2021-08-22 16:09:43 +02:00
|
|
|
//implementation 'se.koc:zutil:1.0.0-SNAPSHOT'
|
2020-08-28 23:07:24 +02:00
|
|
|
|
|
|
|
|
testImplementation 'junit:junit:4.12'
|
|
|
|
|
testImplementation 'org.hamcrest:hamcrest-core:2.2'
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
|
main {
|
|
|
|
|
java {
|
|
|
|
|
srcDirs 'src'
|
|
|
|
|
}
|
2020-11-10 22:02:11 +01:00
|
|
|
//resources {
|
|
|
|
|
// srcDir 'resource'
|
|
|
|
|
//}
|
2020-08-28 23:07:24 +02:00
|
|
|
}
|
|
|
|
|
test {
|
|
|
|
|
java {
|
|
|
|
|
srcDirs 'test'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// ------------------------------------
|
2021-08-29 15:01:44 +02:00
|
|
|
// Hal general configuration
|
2020-08-28 23:07:24 +02:00
|
|
|
// ------------------------------------
|
|
|
|
|
|
|
|
|
|
dependencies {
|
2020-11-10 18:36:02 +01:00
|
|
|
project.subprojects.each { subProject ->
|
2021-09-06 16:40:42 +02:00
|
|
|
runtimeOnly subProject
|
2020-11-10 18:36:02 +01:00
|
|
|
}
|
2020-08-28 23:07:24 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
distributions {
|
2021-08-29 15:01:44 +02:00
|
|
|
distTar.enabled = false
|
|
|
|
|
distZip.enabled = false
|
|
|
|
|
|
2020-08-28 23:07:24 +02:00
|
|
|
main {
|
|
|
|
|
contents {
|
|
|
|
|
from 'hal.conf.example'
|
|
|
|
|
from 'logging.properties'
|
2020-11-10 22:02:11 +01:00
|
|
|
|
2020-11-11 01:48:09 +01:00
|
|
|
from "${buildDir}/resources"
|
2020-08-28 23:07:24 +02:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2020-11-11 01:48:09 +01:00
|
|
|
task copyRecources(type: Copy) {
|
|
|
|
|
doFirst{
|
|
|
|
|
System.out.println("Copying resource files...")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
project.subprojects.each { subProject ->
|
|
|
|
|
from "${subProject.projectDir}/resource"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
into("${buildDir}/resources")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
processResources.finalizedBy(copyRecources)
|
|
|
|
|
|
2020-11-10 16:40:31 +01:00
|
|
|
application {
|
|
|
|
|
mainClass = 'se.hal.HalServer'
|
2020-08-28 23:07:24 +02:00
|
|
|
}
|