53 lines
1.3 KiB
Groovy
53 lines
1.3 KiB
Groovy
plugins {
|
|
id 'java'
|
|
}
|
|
|
|
group 'epub.jgourour' // Replace with your group ID
|
|
version '0.1-SNAPSHOT' // Replace with your version
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
implementation 'info.picocli:picocli:4.7.6'
|
|
implementation 'net.java.dev.jna:jna-platform:5.17.0'
|
|
}
|
|
|
|
jar.enabled = false
|
|
|
|
sourceSets {
|
|
libraries {
|
|
compileClasspath += sourceSets.main.output + sourceSets.test.output // Add dependencies from main and test source sets
|
|
runtimeClasspath += sourceSets.main.output + sourceSets.test.output // Add dependencies from main and test source sets
|
|
java {
|
|
srcDirs = ['src/main/java'] // Define the source directories for Java files\,
|
|
include("*")
|
|
}
|
|
}
|
|
}
|
|
|
|
tasks.register('EncryptEPub', Jar) {
|
|
archiveFileName = 'EncryptEPub.jar'
|
|
manifest {
|
|
attributes 'Main-Class': 'EncryptEPub' // Replace with your main class
|
|
}
|
|
from {sourceSets.main.output.classesDirs}
|
|
dependsOn configurations.runtimeClasspath
|
|
from {
|
|
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
|
|
}
|
|
duplicatesStrategy = DuplicatesStrategy.INCLUDE // Or INCLUDE, EXCLUDE, WARN, INHERIT
|
|
}
|
|
|
|
jar.enabled = false // instead build serverJar, fullJar, i18neditorJar
|
|
|
|
|
|
artifacts {
|
|
archives EncryptEPub
|
|
}
|
|
|
|
test {
|
|
useJUnitPlatform()
|
|
}
|