Skip to content

Fix Maven support - #21

Open
chums122 wants to merge 6 commits into
timiliris:devfrom
chums122:dev
Open

Fix Maven support#21
chums122 wants to merge 6 commits into
timiliris:devfrom
chums122:dev

Conversation

@chums122

@chums122 chums122 commented Feb 7, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR completes Maven support across run/build/deploy paths and removes Maven/Gradle mismatches that caused build lifecycle failures.

What changed

  1. Maven-aware run config defaults

    • Run config default build task is now Maven-aware:
      • Maven project: package
      • Gradle project: shadowJar
    • Updated persisted default and runtime fallback behavior.
  2. Build task UI now adapts by build system

    • Maven projects show Maven goals in the run configuration editor:
      • package
      • clean package
      • install
      • verify
      • clean
    • Gradle projects still show:
      • shadowJar
      • build
      • jar
      • assemble
  3. One-time migration prompt for existing Maven configs

    • On startup, if pom.xml exists and the existing run config uses Gradle-only tasks (build, shadowJar, jar, assemble), the plugin shows a notification with:
      • Migrate to package
      • Keep current task
    • Choice is stored per project so the prompt appears only once.
  4. Maven execution hardening in run state

    • Supports multi-token build input (e.g. clean package).
    • Normalizes Gradle-only tasks to package when executing with Maven.
  5. Hot Reload now supports Maven too

    • HotReloadPluginAction build step now supports:
      • Gradle wrapper / global Gradle
      • Maven wrapper / global Maven
    • Includes Maven goal normalization and multi-token goal support.
    • AR resolution now checks both build/libs and target.
  6. Improved Maven project detection during startup setup

    • isHytaleProject() now also checks pom.xml for Hytale dependency markers:
      • com.hypixel.hytale
      • <artifactId>Server</artifactId>
  7. Better reconfigure messaging

    • Updated error text to include Maven:
      • manifest.json, pom.xml, or build.gradle
  8. Remove duplicate Maven deploy behavior

    • Removed generated maven-resources-plugin copy-to-mods execution from Maven template pom.xml.
    • Deployment is now handled only by the plugin run/deploy flow.
  9. Text encoding cleanup in plugin metadata

    • Replaced non-ASCII separators/arrows in plugin.xml with ASCII-safe equivalents (|, ->) to avoid mojibake.

Why

Maven projects were failing due to Gradle-centric task defaults and options, and hot reload was Gradle-only. This PR aligns defaults, UI, startup behavior, and execution paths with Maven semantics.

Validation

gradlew.bat -q compileKotlin passes after changes.

* Switch run configuration defaults to be Maven-aware (package for Maven projects, shadowJar for Gradle).
* Update build task UI to show Maven goals for Maven projects and include clean package.
* Add one-time startup migration prompt for existing Maven projects using Gradle-only tasks, with actions:
    * Migrate to package
    * Keep current task
* Improve build execution:
    * Support multi-token tasks/goals (e.g. clean package)
    * Normalize Gradle-only task names to package when executing Maven.
* Improve plugin metadata detection by parsing pom.xml (groupId/artifactId/name/version) and returning Maven jar/task defaults.
* Remove Maven template auto-copy (maven-resources-plugin copy-to-mods) so deployment is handled only by the IntelliJ plugin.
-Added Maven support in hot reload build path
- Better Maven detection in startup setup
- Updated outdated Gradle-only message
- Cleaned plugin.xml text for encoding safety
@chums122 chums122 changed the title Fix Maven run workflow: task defaults, migration prompt, and remove duplicate Maven deploy Fix Maven support Feb 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant