From 889db566a30d3cbda919a01365ff1389469e69c7 Mon Sep 17 00:00:00 2001 From: Jan-Willem Harmannij Date: Tue, 3 Oct 2023 21:16:50 +0200 Subject: [PATCH] Set version to 0.7.2, some small cleanups in buildscript --- .../main/groovy/java-gi.library-conventions.gradle | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/buildSrc/src/main/groovy/java-gi.library-conventions.gradle b/buildSrc/src/main/groovy/java-gi.library-conventions.gradle index 6967a1a5..d389377f 100644 --- a/buildSrc/src/main/groovy/java-gi.library-conventions.gradle +++ b/buildSrc/src/main/groovy/java-gi.library-conventions.gradle @@ -31,7 +31,7 @@ dependencies { } group = 'io.github.jwharm.javagi' -version = '0.7.2-SNAPSHOT' +version = '0.7.2' java { if (! System.getenv('CI')) { @@ -46,17 +46,16 @@ java { tasks.register('generateSources', GenerateSources) { // Input directory should point to a clone of the GitHub gircore/gir-files // repository. The location is set in gradle.properties. Default is '../gir-files' - inputDirectory = project.rootDir.toPath().resolve(girFilesLocation).toFile() + inputDirectory = new File(rootDir, girFilesLocation) // Write generated sources to build/generated/sources/java-gi - outputDirectory = layout.buildDirectory.get().dir('generated').dir('sources').dir('java-gi').asFile + outputDirectory = layout.buildDirectory.dir("generated/sources/java-gi") } // Add the generated sources to the main sourceSet -sourceSets.main.java.srcDirs += ['build/generated/sources/java-gi'] +sourceSets.main.java.srcDir(generateSources) tasks.named('compileJava') { - dependsOn generateSources options.compilerArgs += '--enable-preview' options.encoding = 'UTF-8' } @@ -71,10 +70,6 @@ tasks.named('javadoc') { options.encoding = 'UTF-8' } -tasks.named('sourcesJar') { - dependsOn generateSources -} - tasks.named('compileTestJava') { options.compilerArgs += '--enable-preview' options.encoding = 'UTF-8'