[PR #1521] [MERGED] Launcher: the command reference is the same on Windows (unblocks launcher@0.2.2) #3562

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

📋 Pull Request Information

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

Base: main ← Head: fix/launcher-doc-crlf


📝 Commits (1)

  • 52bc81c Launcher: the command reference is the same on Windows

📊 Changes

2 files changed (+20 additions, -1 deletions)

View changed files

➕ .gitattributes (+5 -0)
📝 launcher/src/cli_tools.rs (+15 -1)

📄 Description

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

What

launcher.yml has failed on every run that built since 4d7f30f14 (#1432 was only the first push after the test landed): build windows fails cli_tools::tests::the_launcher_reference_is_up_to_date with "docs/launcher-commands.md is out of date" (latest: run 40029496773). macOS and Linux pass. Because release needs every build, no launcher release has gone out since launcher@0.2.1.

Why

The test came with #1357, after launcher@0.2.1 (the last launcher build, run 39893435651, predates it), so Windows never ran it before 17:17Z. Git for Windows (2.56.0.windows.2 on the runner) checks text out with CRLF (core.autocrlf), and the repository had no .gitattributes, so the checked-out doc never equalled what markdown() generates with \n. markdown() itself has nothing platform-specific: cli.rs has no cfg-gated commands or runtime defaults, bin_name is set explicitly, and rustc normalises CRLF in doc comments. The run below proves it: with LF pinned the Windows test passes.

How

  • .gitattributes: LF on every OS for the three generated files that tests compare byte for byte (docs/launcher-commands.md, docs/horizon-ctl-commands.md, website/src/tokens.css).
  • The launcher's check compares the text whatever line endings the clone gave it (an older clone keeps its CRLF copy until the file is checked out again).
  • New test a_windows_checkout_of_the_reference_is_up_to_date: a CRLF copy of the reference counts as up to date, and a real change does not. It runs on every OS, so it would have caught this on Linux.

Proof

  • Windows CI, gh workflow run launcher --ref fix/launcher-doc-crlf (dry run, publishes nothing): https://github.com/ludovic111/horizon/actions/runs/40035909909. decide, build linux, build macos and build windows passed, and so did sign:
    build windows  test cli_tools::tests::a_windows_checkout_of_the_reference_is_up_to_date ... ok
    build windows  test cli_tools::tests::the_launcher_reference_is_up_to_date ... ok
    build windows  test result: ok. 109 passed; 0 failed; 2 ignored   (lib)
    build windows  test result: ok. 25 passed; 0 failed               (bin)
    build windows  test result: ok. 1 passed; 0 failed                (tests/)
    
    Before, on main (run 40029496773): test result: FAILED. 23 passed; 1 failed. cargo stopped there, so tests/ never ran on Windows.
  • Mac mini: cargo test --release --locked --features gpui/runtime_shaders in launcher/: 113 + 25 + 1 passed. cargo fmt --check is clean.

Release

No version bump is needed. tools/release_train.py decide --kind launcher names the tag (launcher@0.2.2 next) and the build takes the version from it (HORIZON_LAUNCHER_VERSION). Cargo.toml's 0.2.0 only names branch builds. The last decision on main already said release: true, tag: launcher@0.2.2, last: launcher@0.2.1 for #1429, and only this Windows failure stopped it. Once this merges, the next scheduled launcher run (every 10 minutes, on main's newest commit with green checks) ships #1429 as launcher@0.2.2. This PR is labelled skip-release because nothing in it reaches players. #1429 is what counts.

Needs Ludovic

Merge. No other action is needed for launcher@0.2.2.

🤖 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/1521 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/23/2026 **Status:** ✅ Merged **Merged:** 10/24/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/launcher-doc-crlf` --- ### 📝 Commits (1) - [`52bc81c`](https://github.com/horizon-rust/horizon/commit/52bc81ca5b1fe78fe98b63685c0fc0a1c1c6a0ae) Launcher: the command reference is the same on Windows ### 📊 Changes **2 files changed** (+20 additions, -1 deletions) <details> <summary>View changed files</summary> ➕ `.gitattributes` (+5 -0) 📝 `launcher/src/cli_tools.rs` (+15 -1) </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. ## What `launcher.yml` has failed on every run that built since 4d7f30f14 (#1432 was only the first push after the test landed): `build windows` fails `cli_tools::tests::the_launcher_reference_is_up_to_date` with "docs/launcher-commands.md is out of date" (latest: run 40029496773). macOS and Linux pass. Because `release` needs every build, no launcher release has gone out since launcher@0.2.1. ## Why The test came with #1357, after launcher@0.2.1 (the last launcher build, run 39893435651, predates it), so Windows never ran it before 17:17Z. Git for Windows (2.56.0.windows.2 on the runner) checks text out with CRLF (`core.autocrlf`), and the repository had no `.gitattributes`, so the checked-out doc never equalled what `markdown()` generates with `\n`. `markdown()` itself has nothing platform-specific: `cli.rs` has no `cfg`-gated commands or runtime defaults, `bin_name` is set explicitly, and rustc normalises CRLF in doc comments. The run below proves it: with LF pinned the Windows test passes. ## How - `.gitattributes`: LF on every OS for the three generated files that tests compare byte for byte (`docs/launcher-commands.md`, `docs/horizon-ctl-commands.md`, `website/src/tokens.css`). - The launcher's check compares the text whatever line endings the clone gave it (an older clone keeps its CRLF copy until the file is checked out again). - New test `a_windows_checkout_of_the_reference_is_up_to_date`: a CRLF copy of the reference counts as up to date, and a real change does not. It runs on every OS, so it would have caught this on Linux. ## Proof - Windows CI, `gh workflow run launcher --ref fix/launcher-doc-crlf` (dry run, publishes nothing): https://github.com/ludovic111/horizon/actions/runs/40035909909. decide, build linux, build macos and **build windows** passed, and so did sign: ``` build windows test cli_tools::tests::a_windows_checkout_of_the_reference_is_up_to_date ... ok build windows test cli_tools::tests::the_launcher_reference_is_up_to_date ... ok build windows test result: ok. 109 passed; 0 failed; 2 ignored (lib) build windows test result: ok. 25 passed; 0 failed (bin) build windows test result: ok. 1 passed; 0 failed (tests/) ``` Before, on main (run 40029496773): `test result: FAILED. 23 passed; 1 failed`. cargo stopped there, so `tests/` never ran on Windows. - Mac mini: `cargo test --release --locked --features gpui/runtime_shaders` in launcher/: 113 + 25 + 1 passed. `cargo fmt --check` is clean. ## Release No version bump is needed. `tools/release_train.py decide --kind launcher` names the tag (`launcher@0.2.2` next) and the build takes the version from it (`HORIZON_LAUNCHER_VERSION`). Cargo.toml's `0.2.0` only names branch builds. The last decision on main already said `release: true, tag: launcher@0.2.2, last: launcher@0.2.1` for #1429, and only this Windows failure stopped it. Once this merges, the next scheduled launcher run (every 10 minutes, on main's newest commit with green checks) ships #1429 as launcher@0.2.2. This PR is labelled skip-release because nothing in it reaches players. #1429 is what counts. ## Needs Ludovic Merge. No other action is needed for launcher@0.2.2. 🤖 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:10:26 +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#3562
No description provided.