[PR #2591] [MERGED] Launcher: a Horizon version per instance #4454

Closed
opened 2026-11-03 04:17:16 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/2591
Author: @ludovic111
Created: 10/27/2026
Status: ✅ Merged
Merged: 10/27/2026
Merged by: @ludovic111

Base: main ← Head: feat/launcher-instance-version


📝 Commits (1)

  • 90f2755 Launcher: a Horizon version per instance

📊 Changes

9 files changed (+142 additions, -23 deletions)

View changed files

📝 docs/launcher-commands.md (+10 -0)
📝 launcher/README.md (+4 -1)
📝 launcher/src/cli.rs (+17 -2)
📝 launcher/src/instances.rs (+24 -0)
📝 launcher/src/instances/tests.rs (+23 -0)
📝 launcher/src/instances_page.rs (+28 -10)
📝 launcher/src/main.rs (+26 -6)
📝 launcher/src/mcp.rs (+3 -3)
📝 launcher/src/modpacks_page.rs (+7 -1)

📄 Description

🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself.

Clean room: designed from the feature list in briefs/launcher-features-1.md; no other launcher's code, docs or assets were read.

Stacked on #2590 (instances in the window), with it as its base: merge #2587, then #2590, then this one.

What

Launcher feature 2 of 20: a Horizon version per instance, so an old world can stay on the version it was made with.

  • instances.json gets an optional version per instance. Unset (the default) means the launcher's version, which follows updates as today.
  • Play page picker: picking a version keeps the selected instance on it; the launcher's own version is marked FOLLOWS UPDATES, and picking it lets the instance follow again. The hero, Prepare and Play all use the selected instance's version.
  • Sidebar: a pinned instance says Ready · v0.8.0, or v0.7.0 is not installed.
  • CLI / MCP: horizon-launcher instance version <instance> <tag|latest> (MCP instance_version); play, play --instance and MCP play use the pin unless --version is given; a pin that isn't installed is an error that says how to fix it. instance list shows pins.
  • A modpack's own Play button uses that pack's instance version.

The picker no longer changes the launcher's version for every instance: the Versions page and updates still set that.

Picker

How tested

launcher$ cargo fmt --check                                                    ok
launcher$ cargo clippy --all-targets --locked --features gpui/runtime_shaders -- -D warnings   ok
launcher$ cargo test --locked --features gpui/runtime_shaders                  lib 142 passed, bin 35 passed

New test: an_instance_keeps_its_own_version_until_it_follows_updates_again (a pin survives a rename, other instances are unpinned, latest unpins).

On the Mac mini, scratch homes, two stand-in versions (v0.9.0, the launcher's; v0.8.0) whose game binary records which version ran and where:

  • CLI: instance version hardcore v0.8.0 → play --instance hardcore ran v0.8.0 in instances/hardcore; play --instance skyblock (unpinned) ran v0.9.0; --version v0.9.0 overrides the pin; pinning v0.7.0 (not installed) is refused.
  • Window: picker → v0.9.0 (follows updates) removed the pin; picker → v0.8.0 set it; Play started v0.8.0 in instances/hardcore.

Not run on Linux or Windows; CI builds both.

Needs Ludovic

Nothing.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/2591 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/27/2026 **Status:** ✅ Merged **Merged:** 10/27/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `feat/launcher-instance-version` --- ### 📝 Commits (1) - [`90f2755`](https://github.com/horizon-rust/horizon/commit/90f27552459e7868afad4a8527149eb790db6c0c) Launcher: a Horizon version per instance ### 📊 Changes **9 files changed** (+142 additions, -23 deletions) <details> <summary>View changed files</summary> 📝 `docs/launcher-commands.md` (+10 -0) 📝 `launcher/README.md` (+4 -1) 📝 `launcher/src/cli.rs` (+17 -2) 📝 `launcher/src/instances.rs` (+24 -0) 📝 `launcher/src/instances/tests.rs` (+23 -0) 📝 `launcher/src/instances_page.rs` (+28 -10) 📝 `launcher/src/main.rs` (+26 -6) 📝 `launcher/src/mcp.rs` (+3 -3) 📝 `launcher/src/modpacks_page.rs` (+7 -1) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. Clean room: designed from the feature list in briefs/launcher-features-1.md; no other launcher's code, docs or assets were read. Stacked on #2590 (instances in the window), with it as its base: merge #2587, then #2590, then this one. ## What Launcher feature 2 of 20: **a Horizon version per instance**, so an old world can stay on the version it was made with. - `instances.json` gets an optional `version` per instance. Unset (the default) means the launcher's version, which follows updates as today. - **Play page picker**: picking a version keeps the selected instance on it; the launcher's own version is marked **FOLLOWS UPDATES**, and picking it lets the instance follow again. The hero, Prepare and Play all use the selected instance's version. - **Sidebar**: a pinned instance says `Ready · v0.8.0`, or `v0.7.0 is not installed`. - **CLI / MCP**: `horizon-launcher instance version <instance> <tag|latest>` (MCP `instance_version`); `play`, `play --instance` and MCP `play` use the pin unless `--version` is given; a pin that isn't installed is an error that says how to fix it. `instance list` shows pins. - A modpack's own Play button uses that pack's instance version. The picker no longer changes the launcher's version for every instance: the Versions page and updates still set that. ![Picker](https://raw.githubusercontent.com/ludovic111/horizon/screenshots/launcher-features/instance-version/picker.png) ## How tested ``` launcher$ cargo fmt --check ok launcher$ cargo clippy --all-targets --locked --features gpui/runtime_shaders -- -D warnings ok launcher$ cargo test --locked --features gpui/runtime_shaders lib 142 passed, bin 35 passed ``` New test: `an_instance_keeps_its_own_version_until_it_follows_updates_again` (a pin survives a rename, other instances are unpinned, `latest` unpins). On the Mac mini, scratch homes, two stand-in versions (v0.9.0, the launcher's; v0.8.0) whose game binary records which version ran and where: - CLI: `instance version hardcore v0.8.0` → `play --instance hardcore` ran v0.8.0 in `instances/hardcore`; `play --instance skyblock` (unpinned) ran v0.9.0; `--version v0.9.0` overrides the pin; pinning v0.7.0 (not installed) is refused. - Window: picker → v0.9.0 (follows updates) removed the pin; picker → v0.8.0 set it; **Play** started v0.8.0 in `instances/hardcore`. Not run on Linux or Windows; CI builds both. ## Needs Ludovic Nothing. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 04:17:16 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#4454
No description provided.