Add .gitattributes: force LF line-endings for deterministic baseline #5

Merged
imre merged 1 commits from add-gitattributes into main 2026-07-19 18:59:58 +02:00
Owner

Why

There is no .gitattributes, so checkout line-endings depend on the build
host's core.autocrlf. On tanis this yields CRLF, which just broke the
recovery: build-baseline.sh died with /usr/bin/env: 'bash\r', and a
CRLF build tree would push the whole baseline back out of byte-sync with the
docroot (re-triggering the CRLF false-positive storm we just cleaned up).

Fix

* text=auto eol=lf — the source-of-truth LF is authoritative on checkout,
regardless of client core.autocrlf. Binary assets are pinned binary so
git never converts them (byte-exact).

Note on submodules

This covers the top-level repo. The maintenance / common_cadline_libraries
submodules are separate repos — for full determinism either add the same
.gitattributes there, or set core.autocrlf=false on the build host. The
baseline.sls build runs on the host, so a host-level core.autocrlf=false
is the pragmatic belt-and-suspenders until the submodules also carry it.

Root incident + post-mortem: illusion3-salt#895.

## Why There is no `.gitattributes`, so checkout line-endings depend on the build host's `core.autocrlf`. On tanis this yields **CRLF**, which just broke the recovery: `build-baseline.sh` died with `/usr/bin/env: 'bash\r'`, and a CRLF build tree would push the whole baseline back out of byte-sync with the docroot (re-triggering the CRLF false-positive storm we just cleaned up). ## Fix `* text=auto eol=lf` — the source-of-truth LF is authoritative on checkout, regardless of client `core.autocrlf`. Binary assets are pinned `binary` so git never converts them (byte-exact). ## Note on submodules This covers the top-level repo. The `maintenance` / `common_cadline_libraries` submodules are separate repos — for full determinism either add the same `.gitattributes` there, or set `core.autocrlf=false` on the build host. The `baseline.sls` build runs on the host, so a host-level `core.autocrlf=false` is the pragmatic belt-and-suspenders until the submodules also carry it. Root incident + post-mortem: illusion3-salt#895.
imre.agent added 1 commit 2026-07-19 18:38:38 +02:00
Without .gitattributes the checkout line-endings depend on the build
host's core.autocrlf. On the tanis host this produced CRLF: build-baseline.sh
died with `bash\r`, and a CRLF build tree would break the baseline-diff
byte-match. Pin `* text=auto eol=lf` so the source-of-truth LF is
authoritative regardless of client config; binary assets stay byte-exact.

Assisted-by: claude-code@claude-opus-4-8
imre merged commit f8ed190894 into main 2026-07-19 18:59:58 +02:00
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
1 Participants
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: cadline_web/www_archline_hu#5
No description provided.