Replace use of deprecated buildDir property

Signed-off-by: Graham <gpe@openrs2.org>
Graham 1 year ago
parent 49d5c003d8
commit fb9cb2a6b1
  1. 8
      all/build.gradle.kts
  2. 2
      build.gradle.kts

@ -39,10 +39,10 @@ tasks.shadowJar {
tasks.register("generateAuthors") { tasks.register("generateAuthors") {
inputs.dir("$rootDir/.git") inputs.dir("$rootDir/.git")
outputs.file("$buildDir/AUTHORS") outputs.file(layout.buildDirectory.file("AUTHORS"))
doLast { doLast {
Files.newOutputStream(buildDir.toPath().resolve("AUTHORS")).use { out -> Files.newOutputStream(layout.buildDirectory.file("AUTHORS").get().asFile.toPath()).use { out ->
exec { exec {
commandLine("git", "shortlog", "-esn", "HEAD") commandLine("git", "shortlog", "-esn", "HEAD")
standardOutput = out standardOutput = out
@ -80,7 +80,7 @@ distributions {
distributionBaseName.set("openrs2") distributionBaseName.set("openrs2")
contents { contents {
from("$buildDir/AUTHORS") from(layout.buildDirectory.file("AUTHORS"))
from("$rootDir/CONTRIBUTING.md") from("$rootDir/CONTRIBUTING.md")
from("$rootDir/DCO") from("$rootDir/DCO")
from("$rootDir/LICENSE") from("$rootDir/LICENSE")
@ -97,7 +97,7 @@ distributions {
exclude(".*", "*~") exclude(".*", "*~")
into("share") into("share")
} }
from("$buildDir/reports/dependency-license/THIRD-PARTY-NOTICES.txt") { from(layout.buildDirectory.file("reports/dependency-license/THIRD-PARTY-NOTICES.txt")) {
rename { "third-party-licenses.txt" } rename { "third-party-licenses.txt" }
into("share/doc") into("share/doc")
} }

@ -319,7 +319,7 @@ tasks.register<Exec>("publishDokka") {
"ssh -oStrictHostKeyChecking=accept-new", "ssh -oStrictHostKeyChecking=accept-new",
"--delete", "--delete",
"-rtz", "-rtz",
"$buildDir/dokka/htmlCollector/", "${layout.buildDirectory}/dokka/htmlCollector/",
"build@docs.openrs2.org:/srv/www/docs" "build@docs.openrs2.org:/srv/www/docs"
) )
} }

Loading…
Cancel
Save