Files
horizon-mods/scripts/install-tool.sh
T
Ludovic MarieandClaude Opus 5.5 52e1f7d0f9 The registry: coords_hud, the checks, publishing to Pages, the weekly cleanup
- mods/coords_hud.toml: the SDK's example mod, MIT, built from
  crates/horizon-mod-sdk/examples/coords-hud in Horizon.
- check.yml: a pull request's changes, each new file's checks and a trial
  run in the sandbox, the index it would publish (cargo horizon-mod from
  Horizon at HORIZON_REV).
- publish.yml: on main, new versions become releases, index.json and the
  icons go to GitHub Pages.
- cleanup.yml: staging copies nobody needs, weekly.
- CODEOWNERS, the report form, the pull request template, revoked.toml.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-25 15:01:10 +01:00

12 lines
596 B
Bash
Executable File

#!/usr/bin/env bash
# Installs cargo-horizon-mod from Horizon at $HORIZON_REV (a commit; the repository
# variable HORIZON_REV, else main). The registry's checks are that tool's.
set -euo pipefail
rev="${HORIZON_REV:-main}"
if command -v cargo-horizon-mod >/dev/null && [ "$(cat ~/.cargo/horizon-rev 2>/dev/null)" = "$rev" ]; then
exit 0
fi
cargo install --locked --git https://github.com/ludovic111/horizon --rev "$rev" cargo-horizon-mod 2>/dev/null \
|| cargo install --locked --git https://github.com/ludovic111/horizon --branch "$rev" cargo-horizon-mod
echo "$rev" > ~/.cargo/horizon-rev