From 4b48806b3997e39e27bd162c75f9ec6da7488275 Mon Sep 17 00:00:00 2001 From: Jason Penilla <11360596+jpenilla@users.noreply.github.com> Date: Sat, 12 Jun 2021 20:21:59 -0700 Subject: [PATCH] Use `forUseAtConfigurationTime()` for run directory property --- patches/server/Setup-Gradle-project.patch | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/patches/server/Setup-Gradle-project.patch b/patches/server/Setup-Gradle-project.patch index 9d579d391d..2bae6b9953 100644 --- a/patches/server/Setup-Gradle-project.patch +++ b/patches/server/Setup-Gradle-project.patch @@ -107,7 +107,9 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000 +fun TaskContainer.registerRunTask(name: String, block: JavaExec.() -> Unit): TaskProvider = + register(name) { + group = "Paper" -+ workingDir = layout.projectDirectory.dir(providers.gradleProperty("runWorkDir").orElse("run")).get().asFile ++ workingDir = layout.projectDirectory.dir( ++ providers.gradleProperty("runWorkDir").forUseAtConfigurationTime().orElse("run") ++ ).get().asFile + doFirst { + workingDir.mkdirs() + }