[PR #1637] [MERGED] Launcher: install from Horizon's registry, enable and disable, takedowns #3652

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

📋 Pull Request Information

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

Base: main ← Head: feat/launcher-horizon-mods


📝 Commits (2)

  • b49fd60 Launcher: install from Horizon's registry, enable and disable, takedowns
  • 28ad41e Merge feat/launcher-horizon-source (main merged) into feat/launcher-horizon-mods

📊 Changes

8 files changed (+393 additions, -9 deletions)

View changed files

📝 docs/launcher-commands.md (+23 -3)
📝 docs/mod-browser.md (+19 -0)
📝 launcher/src/backend.rs (+1 -0)
📝 launcher/src/browser/horizon.rs (+198 -4)
📝 launcher/src/browser/horizon/tests.rs (+84 -0)
📝 launcher/src/browser/installed.rs (+7 -1)
📝 launcher/src/browser/java.rs (+10 -0)
📝 launcher/src/cli.rs (+51 -1)

📄 Description

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

Stacked on #1636 (the registry as a browser source).

What

Installing from Horizon's registry (launcher/src/browser/horizon.rs), turning its mods on and off, takedowns, and the CLI and the MCP tools generated from it.

  • Search shows whether a project is signed and what a mod may do, in the game's words, before installing.
  • Install downloads to mod-browser/downloads/, runs index::check_file (size, SHA-256, signature, the file's manifest against the entry), then moves a mod to horizon-mods/<id>.hmod, turned on, or a resource pack to resourcepacks/. It refuses an id a folder mod or another entry already has.
  • mods enable|disable <project> switch horizon-mods.txt; remove works for registry mods.
  • --source horizon on mods search|install|....
  • Taken down: a file the index revokes is refused, and installed copies are turned off with the reason: on mods commands, on the Mods page (next PR) and before the game starts (from the kept index, no waiting on the network).
  • Modpacks and shader packs from the registry are not offered yet (modpacks: #1640).
  • Docs: docs/mod-browser.md, docs/launcher-commands.md regenerated.

Based on main with #1576 (virtualized mod lists): this PR doesn't touch the Mods page.

Checked

  • Launcher tests: 122 pass in the lib (2 new: install checked, turned on and removed, with a revocation turning it off; a changed file, a taken id and local files from the real registry refused), 33 in the bin; clippy -D warnings clean; docs/launcher-commands.md regenerated by its test.
  • In isolated folders (mktemp -d for HORIZON_HOME, HORIZON_LAUNCHER_HOME, XDG_*, no self-update, telemetry off) against a local test registry:
$ horizon-launcher mods search --source horizon --kind mod coords
Coordinates HUD  (coords_hud)  Horizon
  Your coordinates, facing and the time of day in a corner of the screen.
  Signed by its author: the launcher checks the signature
  May see your position, health and the time
  May draw text on your screen
  May show you chat messages
$ horizon-launcher mods install --source horizon coords_hud
Coordinates HUD 0.1.0: horizon-mods/coords_hud.hmod (SHA-256:e1135345692f6dd8fd4c51920151944b82333e17049c9bb7d756f27b8deefc53)
$ cat horizon-mods.txt; ls horizon-mods
mod.coords_hud:true
coords_hud.hmod
$ horizon-launcher mods disable coords_hud
Coordinates HUD is off.
[horizon-mods.txt: ]
$ horizon-launcher mods enable coords_hud
Coordinates HUD is on.
[horizon-mods.txt: mod.coords_hud:true]
$ horizon-launcher mods install --source horizon cozy
error: Cozy is a modpack in Horizon's registry: this launcher can't install those yet.
# the test index now takes coords_hud down
$ horizon-launcher mods list
Coordinates HUD was taken down and is off: Test takedown.
Coordinates HUD  0.1.0  (Horizon, coords_hud)
  horizon-mods/coords_hud.hmod  SHA-256:e1135345692f6dd8fd4c51920151944b82333e17049c9bb7d756f27b8deefc53
[horizon-mods.txt: ]
$ horizon-launcher mods enable coords_hud
error: Coordinates HUD was taken down: Test takedown.
$ horizon-launcher mods remove coords_hud
Removed Coordinates HUD (horizon-mods/coords_hud.hmod).

pr_ready (tools/pr_ready.py --quick --base feat/launcher-horizon-source on ludovics-mac-mini, against feat/launcher-horizon-source at 7e513d2d5, 1 min 49 s)

Check Result
Scope ✅ 8 files, +393 −9
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ➖ no Python change
rustfmt ➖ no Rust change
clippy ➖ no Rust change
tests ➖ no crate touched
doc tests ➖ no crate touched
tokens.css up to date ➖ theme untouched
launcher rustfmt ✅ (2 s)
launcher clippy ✅ (7 s)
launcher tests ✅ 122 passed (16 s)
Parity ➖ no harness affected
Label player-facing: feature if players get something new, no label for a fix (release-now if urgent)

🤖 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/1637 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/24/2026 **Status:** ✅ Merged **Merged:** 10/25/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `feat/launcher-horizon-mods` --- ### 📝 Commits (2) - [`b49fd60`](https://github.com/horizon-rust/horizon/commit/b49fd602df9dd5ebe00fa23bfd5316390544d729) Launcher: install from Horizon's registry, enable and disable, takedowns - [`28ad41e`](https://github.com/horizon-rust/horizon/commit/28ad41eb2207be5e36f31d422f5166c9d68aaf80) Merge feat/launcher-horizon-source (main merged) into feat/launcher-horizon-mods ### 📊 Changes **8 files changed** (+393 additions, -9 deletions) <details> <summary>View changed files</summary> 📝 `docs/launcher-commands.md` (+23 -3) 📝 `docs/mod-browser.md` (+19 -0) 📝 `launcher/src/backend.rs` (+1 -0) 📝 `launcher/src/browser/horizon.rs` (+198 -4) 📝 `launcher/src/browser/horizon/tests.rs` (+84 -0) 📝 `launcher/src/browser/installed.rs` (+7 -1) 📝 `launcher/src/browser/java.rs` (+10 -0) 📝 `launcher/src/cli.rs` (+51 -1) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. Stacked on #1636 (the registry as a browser source). ## What Installing from Horizon's registry (`launcher/src/browser/horizon.rs`), turning its mods on and off, takedowns, and the CLI and the MCP tools generated from it. - Search shows whether a project is signed and what a mod may do, in the game's words, before installing. - Install downloads to `mod-browser/downloads/`, runs `index::check_file` (size, SHA-256, signature, the file's manifest against the entry), then moves a mod to `horizon-mods/<id>.hmod`, turned on, or a resource pack to `resourcepacks/`. It refuses an id a folder mod or another entry already has. - `mods enable|disable <project>` switch `horizon-mods.txt`; `remove` works for registry mods. - `--source horizon` on `mods search|install|...`. - Taken down: a file the index revokes is refused, and installed copies are turned off with the reason: on `mods` commands, on the Mods page (next PR) and before the game starts (from the kept index, no waiting on the network). - Modpacks and shader packs from the registry are not offered yet (modpacks: #1640). - Docs: `docs/mod-browser.md`, `docs/launcher-commands.md` regenerated. Based on main with #1576 (virtualized mod lists): this PR doesn't touch the Mods page. ## Checked - Launcher tests: 122 pass in the lib (2 new: install checked, turned on and removed, with a revocation turning it off; a changed file, a taken id and local files from the real registry refused), 33 in the bin; clippy `-D warnings` clean; `docs/launcher-commands.md` regenerated by its test. - In isolated folders (`mktemp -d` for `HORIZON_HOME`, `HORIZON_LAUNCHER_HOME`, `XDG_*`, no self-update, telemetry off) against a local test registry: ``` $ horizon-launcher mods search --source horizon --kind mod coords Coordinates HUD (coords_hud) Horizon Your coordinates, facing and the time of day in a corner of the screen. Signed by its author: the launcher checks the signature May see your position, health and the time May draw text on your screen May show you chat messages $ horizon-launcher mods install --source horizon coords_hud Coordinates HUD 0.1.0: horizon-mods/coords_hud.hmod (SHA-256:e1135345692f6dd8fd4c51920151944b82333e17049c9bb7d756f27b8deefc53) $ cat horizon-mods.txt; ls horizon-mods mod.coords_hud:true coords_hud.hmod $ horizon-launcher mods disable coords_hud Coordinates HUD is off. [horizon-mods.txt: ] $ horizon-launcher mods enable coords_hud Coordinates HUD is on. [horizon-mods.txt: mod.coords_hud:true] $ horizon-launcher mods install --source horizon cozy error: Cozy is a modpack in Horizon's registry: this launcher can't install those yet. # the test index now takes coords_hud down $ horizon-launcher mods list Coordinates HUD was taken down and is off: Test takedown. Coordinates HUD 0.1.0 (Horizon, coords_hud) horizon-mods/coords_hud.hmod SHA-256:e1135345692f6dd8fd4c51920151944b82333e17049c9bb7d756f27b8deefc53 [horizon-mods.txt: ] $ horizon-launcher mods enable coords_hud error: Coordinates HUD was taken down: Test takedown. $ horizon-launcher mods remove coords_hud Removed Coordinates HUD (horizon-mods/coords_hud.hmod). ``` **pr_ready** (`tools/pr_ready.py --quick --base feat/launcher-horizon-source` on ludovics-mac-mini, against feat/launcher-horizon-source at 7e513d2d5, 1 min 49 s) | Check | Result | | --- | --- | | Scope | ✅ 8 files, +393 −9 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ➖ no Python change | | rustfmt | ➖ no Rust change | | clippy | ➖ no Rust change | | tests | ➖ no crate touched | | doc tests | ➖ no crate touched | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ✅ (2 s) | | launcher clippy | ✅ (7 s) | | launcher tests | ✅ 122 passed (16 s) | | Parity | ➖ no harness affected | | Label | player-facing: `feature` if players get something new, no label for a fix (`release-now` if urgent) | 🤖 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:11:10 +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#3652
No description provided.