Skip to content

Create PaperMC plugin to auto-update ViaVersion - #1

Merged
windcolor-dev merged 4 commits into
mainfrom
copilot/create-auto-update-viaversion-plugin
Apr 6, 2026
Merged

Create PaperMC plugin to auto-update ViaVersion#1
windcolor-dev merged 4 commits into
mainfrom
copilot/create-auto-update-viaversion-plugin

Conversation

Copilot AI commented Apr 5, 2026

Copy link
Copy Markdown
  • Create PaperMC plugin source
  • Add GitHub Actions Maven build workflow
  • Fix Java version: bump pom.xml and workflow from 17 → 21 (Paper API 1.21.4 requires Java 21)
Original prompt

Create an advanced PaperMC Plugin that auto updates ViaVersion to the latest version.

Copilot AI changed the title [WIP] Add advanced PaperMC plugin for auto updating ViaVersion Create PaperMC plugin to auto-update ViaVersion Apr 5, 2026
@windcolor-dev
windcolor-dev marked this pull request as ready for review April 5, 2026 20:34

@windcolor-dev windcolor-dev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey is it able to detect the name of the old jar?

Copilot AI commented Apr 5, 2026

Copy link
Copy Markdown
Author

Hey is it able to detect the name of the old jar?

Yes — the plugin scans the plugins/ folder for any .jar file whose name starts with viaversion (case-insensitive) via the findExistingViaVersionJar method in UpdateChecker.java. It handles arbitrary version suffixes (e.g. ViaVersion-4.9.2.jar, ViaVersion-5.0.0-beta1.jar). Once a newer version is downloaded, the old jar is deleted by name.

@windcolor-dev windcolor-dev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Final change:
Run a maven workflow to build the jar and upload it onto github

Copilot AI commented Apr 5, 2026

Copy link
Copy Markdown
Author

Final change:
Run a maven workflow to build the jar and upload it onto github

Done in ab77fa6. Added .github/workflows/build.yml which:

  • Runs mvn package on pushes to main, pull requests against main, and manual dispatches
  • Uploads the built jar as a workflow artifact on every run
  • Creates a GitHub Release with the jar attached whenever a v* tag is pushed

…PI 1.21.4 compatibility

Agent-Logs-Url: https://github.com/Windpvp/viaversion-auto-update/sessions/45b32680-78e7-4143-9654-67b2d0169118

Co-authored-by: windcolor-dev <79166388+windcolor-dev@users.noreply.github.com>
@windcolor-dev
windcolor-dev merged commit 5a151d8 into main Apr 6, 2026
1 check passed
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.

2 participants