From a2db3c3278e685dc83889a90d74b798a638a3317 Mon Sep 17 00:00:00 2001 From: JeremyStarTM Date: Wed, 25 Dec 2024 01:57:42 +0100 Subject: [PATCH] Replace 'project' with 'this@allprojects' --- build.gradle.kts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 32bfc49..6fb8a5e 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -215,7 +215,7 @@ allprojects { dokkaSourceSets.configureEach { // Metadata - displayName = project.name + displayName = this@allprojects.name documentedVisibilities = setOf(DokkaConfiguration.Visibility.PUBLIC, DokkaConfiguration.Visibility.PROTECTED) reportUndocumented = false skipEmptyPackages = false @@ -224,8 +224,8 @@ allprojects { // Source link sourceLink { - localDirectory = projectDir.resolve("src") - remoteUrl = URI("https://git.staropensource.de/StarOpenSource/Engine/src/branch/develop/" + project.name.replace(":", "/") + "/src").toURL() + localDirectory = this@allprojects.projectDir.resolve("src") + remoteUrl = URI("https://git.staropensource.de/StarOpenSource/Engine/src/branch/develop/" + this@allprojects.name.replace(":", "/") + "/src").toURL() remoteLineSuffix = "#L" } } @@ -241,18 +241,18 @@ allprojects { dateFormatTimeZone = "UTC" } - // -> Copy task + // -> Add input tasks.register("copyGitProperties") { dependsOn(tasks.generateGitProperties) - inputs.file("${project.projectDir}/build/resources/main/git.properties") + inputs.file("${this@allprojects.projectDir}/build/resources/main/git.properties") doLast { - if (rootProject == project) + if (rootProject == this@allprojects) return@doLast file(inputs.files.first()) .copyTo( - file("${project.projectDir}/src/main/resources/sosengine-${project.name.replace(":", "-")}-git.properties"), + file("${this@allprojects.projectDir}/src/main/resources/sosengine-${this@allprojects.name.replace(":", "-")}-git.properties"), overwrite = true ) } @@ -263,7 +263,7 @@ allprojects { // Gradle properties tasks.register("copyGradleProperties") { - inputs.file("${project(":").projectDir.path}/gradle.properties") + inputs.file("${rootProject.projectDir.path}/gradle.properties") doLast { if (rootProject == project) @@ -271,7 +271,7 @@ allprojects { file(inputs.files.first()) .copyTo( - file("${project.projectDir}/src/main/resources/sosengine-${project.name.replace(":", "-")}-gradle.properties"), + file("${this@allprojects.projectDir}/src/main/resources/sosengine-${this@allprojects.name.replace(":", "-")}-gradle.properties"), overwrite = true ) }