add module-info
This commit is contained in:
@@ -9,6 +9,7 @@ plugins {
|
||||
}
|
||||
|
||||
java {
|
||||
modularity.inferModulePath = true
|
||||
toolchain {
|
||||
languageVersion = JavaLanguageVersion.of(25)
|
||||
}
|
||||
@@ -22,6 +23,10 @@ repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
application {
|
||||
mainClass = 'edu.addressbook.view.ApplicationView'
|
||||
}
|
||||
|
||||
javafx {
|
||||
version = "25.0.1"
|
||||
modules = [ 'javafx.controls', 'javafx.fxml', 'javafx.graphics', 'javafx.web' ]
|
||||
@@ -42,14 +47,23 @@ dependencies {
|
||||
|
||||
}
|
||||
|
||||
// Apply a specific Java toolchain to ease working on different environments.
|
||||
java {
|
||||
toolchain {
|
||||
languageVersion = JavaLanguageVersion.of(25)
|
||||
}
|
||||
jar {
|
||||
manifest {
|
||||
attributes 'Automatic-Module-Name': group,
|
||||
'Main-Class': application.mainClass,
|
||||
'Class-Path': 'edu.addressbook.view edu.addressbook org.aspectj.runtime'
|
||||
}
|
||||
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
||||
from { configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) } }
|
||||
}
|
||||
|
||||
application {
|
||||
// Define the main class for the application.
|
||||
mainClass = 'edu.addressbook.view.ApplicationView'
|
||||
tasks.named('jar') {
|
||||
manifest {
|
||||
attributes(
|
||||
'Automatic-Module-Name':'edu.addressbook',
|
||||
'Implementation-Title': 'edu.addressbook',
|
||||
'Implementation-Version': 1.0,
|
||||
'Main-Class': application.mainClass,
|
||||
'Class-Path': 'edu.addressbook org.aspectj.runtime' )
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user