From 75e82fe754f34e454e5d30029fc7b4a29f4d5c5e Mon Sep 17 00:00:00 2001 From: Joseph Hale Date: Sat, 13 Dec 2025 17:04:01 -0700 Subject: [PATCH] build: Resolve plugin.yml no matter the `cwd` Fixes Intellisense in VS Code since the Gradle plugin runs the script from a different directory. --- app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index e4de37a..c864dae 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -199,7 +199,7 @@ String mostRecentVersion( List versions ) { def getPluginYml() { // Read in the plugin.yml file for the Minecraft Plugin. // Aided by https://stackoverflow.com/a/48320319/14765128 - String PLUGIN_YML_PATH = "app/src/main/resources/plugin.yml" + String PLUGIN_YML_PATH = new File(buildscript.sourceFile.parent, "src/main/resources/plugin.yml").absolutePath InputStream pluginYml = new File(PLUGIN_YML_PATH).newInputStream() return new org.yaml.snakeyaml.Yaml().load(pluginYml) } -- 2.51.2