Ensure plugin.yml token expansions (e.g. api-version) are preserved in the shaded JAR by packaging processed resources rather than raw resource files.
Provide a safe fallback for particle menus so the plugin does not fail when a versioned particles_<version>.yml is missing.
Prevent runtime failures when importing default menus into the database by shipping built-in menus/*.yml files.
Description
Updated tasks.shadowJar to include processed resources via from(sourceSets.main.get().output) so resource filtering and token expansion are packaged into the shaded JAR.
Added fallback logic in ResourceUtil.getMostCompatibleParticlesMenu() to return core.getResource("menus/particles.yml") when the versioned menu resource is not present.
Left existing shadow exclusions and relocation settings intact to preserve packaging behavior.
Testing
Ran ./gradlew processResources, which completed successfully and produced build/resources/main/menus containing particles.yml and purchase_menu.yml.
Attempted ./gradlew shadowJar, which failed due to external dependency resolution errors (HTTP 403) unrelated to resource packaging.
No additional automated builds were run after switching to from(sourceSets.main.get().output).
### Motivation
- Ensure `plugin.yml` token expansions (e.g. `api-version`) are preserved in the shaded JAR by packaging processed resources rather than raw resource files.
- Provide a safe fallback for particle menus so the plugin does not fail when a versioned `particles_<version>.yml` is missing.
- Prevent runtime failures when importing default menus into the database by shipping built-in `menus/*.yml` files.
### Description
- Updated `tasks.shadowJar` to include processed resources via `from(sourceSets.main.get().output)` so resource filtering and token expansion are packaged into the shaded JAR.
- Added fallback logic in `ResourceUtil.getMostCompatibleParticlesMenu()` to return `core.getResource("menus/particles.yml")` when the versioned menu resource is not present.
- Left existing shadow exclusions and relocation settings intact to preserve packaging behavior.
### Testing
- Ran `./gradlew processResources`, which completed successfully and produced `build/resources/main/menus` containing `particles.yml` and `purchase_menu.yml`.
- Attempted `./gradlew shadowJar`, which failed due to external dependency resolution errors (HTTP 403) unrelated to resource packaging.
- No additional automated builds were run after switching to `from(sourceSets.main.get().output)`.
------
[Codex Task](https://chatgpt.com/codex/tasks/task_e_69590ba2c004832fa163bd963c6813a7)
Pull request closed
Please reopen this pull request to perform a merge.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Motivation
plugin.ymltoken expansions (e.g.api-version) are preserved in the shaded JAR by packaging processed resources rather than raw resource files.particles_<version>.ymlis missing.menus/*.ymlfiles.Description
tasks.shadowJarto include processed resources viafrom(sourceSets.main.get().output)so resource filtering and token expansion are packaged into the shaded JAR.ResourceUtil.getMostCompatibleParticlesMenu()to returncore.getResource("menus/particles.yml")when the versioned menu resource is not present.Testing
./gradlew processResources, which completed successfully and producedbuild/resources/main/menuscontainingparticles.ymlandpurchase_menu.yml../gradlew shadowJar, which failed due to external dependency resolution errors (HTTP 403) unrelated to resource packaging.from(sourceSets.main.get().output).Codex Task
Pull request closed