Skip to content

Switch to semantic versioning with weekly dev and monthly release builds - #166

Merged
Travja merged 7 commits into
devfrom
claude/semver-releases
Oct 23, 2026
Merged

Travja merged 7 commits into
devfrom
claude/semver-releases

Conversation

@Travja

@Travja Travja commented Oct 22, 2026 •

Copy link
Copy Markdown
Collaborator

This is the same change as magemonkeystudio/divinity#349 and magemonkeystudio/fabled#1868. CI stops committing version bumps. The version is worked out at build time instead: the last release tag, bumped by the highest build:major/build:minor/build:patch label among the PRs merged since.

Changes

  • Merges main into dev. This brings over 2390c03 (Clone ItemsAdder items on creation: ItemsAdderProvider.create() returns .clone()). That fix was only ever committed to main, so it's a real code change for dev. The merge also lets the monthly release fast-forward main.
  • pom.xml: <version>${revision}${changelist}</version> plus flatten-maven-plugin.
    • codex-api, codex-core, codex-plugin and codex-bungee point their <parent> at the same expression.
    • The codex-nms modules keep their own fixed versions, as before (the old bump script skipped them too).
  • devbuild.yml: weekly X.Y.Z-SNAPSHOT of dev on JDK 25 with -DskipNms (Mondays 12:17 UTC), skipped if nothing was committed that week. Can be run by hand.
  • release.yml: monthly X.Y.Z release on JDK 25 with the BuildTools step and the nms profile. It runs on the 1st at 13:23 UTC, ahead of Fabled (14:53) and Divinity (15:23). It tags dev, deploys, creates a GitHub Release with codex-X.Y.Z.jar, and fast-forwards main.
  • semver-label.yml: a PR into dev needs exactly one of build:major, build:minor or build:patch. The plain major/minor/patch labels Dependabot adds by itself are ignored. Dependabot PRs get build:patch.
  • README: release and dev version badges next to the Release Build and Dev Build status badges. This also fixes the badge links, which pointed at magemonkeystudios.

Since #173 merged, this PR is merged up to it: pom-dev.xml is gone (the dev build uses -DskipNms instead), and both workflows pass java_version: '25'.

First release: 1.2.0

The last release is 1.1.1-R1, so with no labels the first release would be 1.1.2. That's below Divinity's MIN_CORE_VERSION (1.2.0-R0.7-SNAPSHOT), and Divinity would disable itself. I've put build:minor on #153, which adds new Compat API, so the first release is 1.2.0. That passes Divinity's and Fabled's version checks.

Before merging

  • .github patch 0005 is applied. It adds the java_version input to reusable-semver-build.yml. Without it, both workflows here fail at startup with an unknown input. The same patch adds it to the old reusable-build.yml, which fixes the workflows Build on JDK 25, bump WorldEdit/WorldGuard, replace pom-dev.xml with a profile #173 left on dev.
  • The .github patch that switches the shared workflows to build:* labels is applied.
  • The shared workflows (reusable-semver-build.yml, reusable-semver-label.yml, actions/next-version) are in magemonkeystudio/.github main.
  • The 15 tags from before April 2024 are deleted.
  • The .github patch that runs BuildTools for 26.2/26.3 is applied.

After merging

  • Make label / semver-label a required check on dev.
  • Point Divinity's and Fabled's codex.version at a release or 1.2.0-SNAPSHOT. The R0.x-SNAPSHOT versions they use now won't get new builds.

Testing

  • On Temurin 25, mvn package -DskipNms -Drevision=1.2.0 -Dchangelist=-SNAPSHOT (the dev build) builds all modules at 1.2.0-SNAPSHOT. codex-1.2.0-SNAPSHOT.jar (in ../build, where the release step picks it up) has version: 1.2.0-SNAPSHOT, and every module's flattened pom has the resolved parent version.
  • With -P gpg,publish and no -DskipNms (the release build), the reactor includes the NMS modules and passes mvn validate. I didn't run a full release build because it needs the BuildTools jars.
  • The version script on Codex's history picks 1.1.1-R1 as the last release and gives 1.2.0 with Add equipment-slot-scoped attribute modifier support to Compat #153 labeled build:minor.
  • actionlint passes on the new workflows.

Generated by Claude Code

Brings over 2390c03 (Clone ItemsAdder items on creation), a fix that was
only ever committed to main.
Same change as magemonkeystudio/divinity#349. CI no longer commits
version bumps. The shared reusable-semver-build.yml works out the
version from the last release tag and the major/minor/patch labels of
the PRs merged since, then passes it to Maven as
-Drevision/-Dchangelist.

- pom.xml and pom-dev.xml: <version>${revision}${changelist}</version>
  plus flatten-maven-plugin. codex-api, codex-core, codex-plugin and
  codex-bungee point their <parent> at the same expression (they
  inherit from pom.xml in both builds). The codex-nms modules keep
  their own fixed versions, as before.
- devbuild.yml: weekly X.Y.Z-SNAPSHOT of dev from pom-dev.xml (Mondays
  12:17 UTC), skipped when nothing was committed that week.
- release.yml: monthly X.Y.Z release from pom.xml with the Spigot
  BuildTools step (1st of the month 13:23 UTC, before Fabled and
  Divinity). It tags dev, deploys, creates a GitHub release and
  fast-forwards main.
- semver-label.yml: PRs into dev need exactly one of major, minor or
  patch. Dependabot PRs get patch.
- README: the version comes from a release badge. This also fixes the
  badge links, which pointed at "magemonkeystudios".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Secz6aiBJ7U8im8tnYhyLA
@Travja
Travja force-pushed the claude/semver-releases branch from c3dd61f to d8cb289 Compare October 22, 2026 18:34
@Travja Travja added build:patch and removed build:patch labels Oct 22, 2026 — with Claude
@Travja
Travja marked this pull request as ready for review October 22, 2026 21:10
# Conflicts:
#	.github/dependabot.yml
Dependabot adds plain major/minor/patch labels by itself, based on the
dependency's own version jump. The shared workflows now read prefixed
build:* labels and ignore the plain ones. Dependabot PRs get
build:patch here instead of patch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Secz6aiBJ7U8im8tnYhyLA
@Travja Travja added build:major and removed build:major labels Oct 22, 2026 — with Claude
@Travja Travja added build:patch and removed build:patch labels Oct 22, 2026 — with Claude
The README now has a release version badge next to the Release Build
status badge, and a dev snapshot version badge next to the Dev Build
status badge.

The dev version is read from the snapshot repo's maven-metadata.xml
using shields.io's highestVersion strategy, because the metadata has
no <latest> entry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Secz6aiBJ7U8im8tnYhyLA
Brings in #173, which deleted pom-dev.xml in
favour of an nms profile (-DskipNms) and moved Codex to JDK 25.

- pom-dev.xml stays deleted. Its version change is no longer needed.
- devbuild.yml keeps the semver workflow call and takes #173's
  maven_args '-DskipNms' and java_version '25'. release.yml merged
  cleanly with java_version '25'.

Needs the java_version input in reusable-semver-build.yml
(magemonkeystudio/.github patch 0005).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Secz6aiBJ7U8im8tnYhyLA
@Travja
Travja merged commit e9a79d4 into dev Oct 23, 2026
3 checks passed
@Travja
Travja deleted the claude/semver-releases branch October 24, 2026 02:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants