Тест поймал: задокументированная команда гейта была сломана.
nix develop .#fmt --command treefmt -- --fail-on-change .
-> Error: failed to create walker: path .../--fail-on-change not found
`nix develop --command` передаёт разделитель `--` самому treefmt'у как
позиционный аргумент, и тот считает его именем каталога. Правильно:
nix develop .#fmt --command treefmt --fail-on-change . # exit 0
nix develop .#fmt --command bash -c 'treefmt --fail-on-change .' # тоже
Попутно подтверждено: полный `nix flake check` (с билдом) на этой ветке
проходит — exit 0, all checks passed, включая checks.deploy-schema и
checks.deploy-activate. И devshell .#fmt собирается: в PATH treefmt, nixfmt,
shfmt и shellcheck.
treefmt --fail-on-change падал на файлах, которые сама эта ветка и принесла:
checks.sh, config-fingerprint.sh и runtime-drift.sh не были shfmt-чистыми.
Форматтер, который красный на собственной ветке, — не форматтер.
Сделано:
* три скрипта этой ветки отформатированы (shfmt -i 2 -ci);
* .agent/src/install.sh исключён из treefmt: он старый, 487 строк diff'а,
и переписывать чужой инсталлятор — решение владельца, не форматтера;
* shellcheck добавлен в devshell .#fmt и в checks.sh (check #13); если
shellcheck нет в PATH — проверка SKIP, а не FAIL;
* поправлены протухшие комментарии treefmt.toml: output'а formatter у
флейка нет (ADR-0011), а .ci/flake-checks.nix удалён.
Заодно в шапке config-fingerprint.sh зафиксирован грабли, который стоил
часа поиска: обе ревизии надо материализовать одинаково (git archive),
иначе исполняемый бит одного файла меняет store path whitesur-kde, а за
ним system-path, XDG_DATA_DIRS и X-Restart-Triggers — при полностью
идентичном содержимом.
treefmt.toml: nixfmt для .nix, shfmt для .sh. Все 137 отслеживаемых .nix
файлов уже nixfmt-чистые — форматтер теперь страхует от дрейфа, а не
переформатирует репозиторий. Ничего не форматируется автоматически.
Форматтер доступен как `nix develop .#fmt` (treefmt + nixfmt + shfmt).
Output `formatter` у флейка быть не может — см. пояснение в flake.nix.
Раннер на sapphira отдаёт job'у PATH, равный своему hostPackages, и он
фиксируется в systemd-юните при активации -- чтобы добавить туда инструмент,
нужен nixos-rebuild switch на хосте. Для workflow'ов в oqyude/winos это тупик:
jq (scripts/update-manifest.sh) и pwsh (scripts/update-kvrt.ps1) в наборе
раннера отсутствуют, а nix-shell -p не запасной путь -- реестр nix на sapphira
пустой, каналов нет, -p не находит nixpkgs.
Что сделано:
- lib/ci-tools.nix -- один список инструментов CI.
- devshells/default.nix: devshell `ci` (nix develop .#ci) с этим списком.
Workflow может взять PATH devshell'а и получить jq/pwsh без пересборки:
nix develop /etc/nixos#ci --command bash -c 'echo $PATH'
- modules/server/gitea-runner.nix: hostPackages берёт тот же список, чтобы
набор раннера и devshell не расходились; в списке теперь ещё и powershell.
Проверка: devshell собирается на sapphira (nix develop /etc/nixos#ci) и
отдаёт jq и pwsh.
Playwright never reads this variable. Verified: no reference to it anywhere
in playwright-core, unsetting it leaves the suite green, and pointing
PLAYWRIGHT_BROWSERS_PATH at an empty directory fails the suite even while
the variable is set. The browsers.json-derived symlink farm is the only
mechanism that selects the nixpkgs chromium.
The old comment claimed the variable was "honoured by older Playwright and
the channel code path", which is false. That claim risked a future editor
deciding the symlink farm was secondary and breaking a working setup.
Replaced it with a note recording why the export must not come back.
Suite re-verified after the change: 15/15 passed.
the banner pointed at ../VeeamTimelineView, which exists nowhere - on
sapphira the repo is on the external disk. the chromium revision was
hardcoded to 1248 and would have silently broken the next time the
project bumps @playwright/test; read it from the project's own
playwright-core/browsers.json instead.
Sister project at S:\Git\VeeamTimelineView has its own repo and gitea
remote; we keep its Nix env here in the home-fleet flake so the project
itself stays free of Nix.
`nix develop .#vtimeline` provides:
- nodejs_22 (Node 20 hit EOL 2026-04-30 and was removed from nixpkgs)
- python3 (Playwright webServer)
- chromium (used via PLAYWRIGHT_BROWSERS_PATH symlink farm, since
Playwright 1.40+ hard-codes a separate chrome-headless-shell path)
Shell banner points at ../VeeamTimelineView. The absolute project path
cannot be baked into the shellHook (Nix forbids escaping the flake source
dir at eval time); user is expected to `cd` themselves.