| name | update-versions |
| description | Refresh the Minecraft version numbers in src/data.ts by pinging every listed server and scanning every listed library repo. Use when asked to update, refresh, or check the versions on minestom.rocks, to find which servers are down, or to bump latestVersion after a new Minestom release. |
Update versions in data.ts
src/data.ts lists servers, libraries, and projects with a version field holding the
Minecraft version each one targets. This skill re-derives every one of those from a live
source: an SLP ping for servers, the pinned net.minestom:minestom coordinate for repos.
1. Refresh the protocol map
Protocol numbers are what servers actually report, so the map must be current after a Minestom
release:
bash .claude/skills/update-versions/scripts/rebuild-protocol-map.sh ~/references/minestom
latestVersion in data.ts should be the newest tagged Minestom release (git tag --sort=-creatordate | head -1 in that repo), not whatever master is on — master usually sits
on an unreleased snapshot.
2. Ping the servers
python3 .claude/skills/update-versions/scripts/ping-servers.py
Reads the server list straight out of src/data.ts (skipping commented-out entries), resolves
_minecraft._tcp SRV records, and prints listed vs. reported version side by side.
The script opens raw TCP to Minecraft ports, which a restricted network environment may block.
The tell is that connections hang past the 8s socket timeout instead of erroring, and every
server appears unreachable at once. That is an environment problem, not an outage — say so and
ask how to proceed rather than marking the whole list as down.
Reading the output:
- Trust the protocol number first. Reported names are free text and frequently stale,
truncated, or decorative (
§61.7-1.21, Velocity 1.7.2-26.2, 1.21.7-26.2).
- Protocol is ambiguous for some versions — see
reference/protocol-versions.json. 775 is
both 26.1.1 and 26.1.2; 772 is both 1.21.7 and 1.21.8. When the map returns two candidates,
use the reported name to break the tie.
protocol: -1 means the server echoes back whatever you sent, so the number is
meaningless. Re-ping with two different protocol numbers to confirm it is echoing rather than
genuinely reporting. Then fall back to the reported name — and if that name is itself
ambiguous or looks like a partial string, check the server's website or Discord before
writing it down. CounterMine reports a bare 1.21.11 over SLP while its site says
1.21.11-26.2; the real answer is 26.2.
- Ping twice before believing a server is down. Only mark it down if it fails repeatedly,
and try the bare domain and
mc. subdomain too, not just the listed IP.
3. Scan the library repos
bash .claude/skills/update-versions/scripts/scan-libraries.sh
Clones every GitHub repo linked from data.ts (blobless, cached in
/tmp/minestom-rocks-libcheck) and prints the Minestom coordinate found on each of its 8 most
recently pushed branches, flagging the default branch.
Map the coordinate to a Minecraft version by its suffix: 2026.07.22-26.2 → 26.2,
1_21_9-SNAPSHOT → 1.21.9. A bare commit hash (net.minestom:minestom-snapshots:7589b3b655)
needs a lookup in a Minestom clone:
git -C ~/references/minestom show <hash>:src/autogenerated/java/net/minestom/server/MinecraftConstants.java | grep VERSION_NAME
Older commits keep that constant in src/main/java/net/minestom/server/MinecraftServer.java.
Which branch counts
Check non-default branches — several libraries genuinely develop off-default (LuckPerms ships
from feat/minestom, Terra from dev/*). But only count a branch that represents the
library's real development line. A newer version sitting on an unmerged branch does not mean
the library supports it. Confirm with gh pr list -R <owner>/<repo>:
- Renovate/Dependabot bot branches — never count.
- An open PR that has not landed — do not count; report it to the user instead.
- The default branch, or a maintainer's long-lived version branch that is the default —
count it.
When a library's newest version only exists on an unmerged branch, leave the entry alone and
tell the user, so they can decide.
4. Apply the edits
Edit version fields in src/data.ts in place. Notes:
- The
version type only permits X.Y or X.Y.Z, so 26.2 is valid.
- Entries are sorted at runtime at the bottom of the file — never hand-reorder them.
- Comment out servers that are confirmed down, matching the existing style:
// prefix on
each line of the object, indentation preserved, trailing // },. Uncomment one if it comes
back up.
bunx tsc --noEmit reports pre-existing tsconfig errors in this repo; they are unrelated.
Split the result into atomic commits (version bumps separately from adding/removing servers),
lowercase messages, no prefixes.