mirror of
https://github.com/Donkie/Spoolman.git
synced 2026-10-22 01:52:17 -05:00
The root .gitattributes sets `* text=auto`, so a Windows checkout gets CRLF in the working tree. Prettier defaults to `endOfLine: "lf"` and therefore reports every text file as mis-formatted -- 163 files in client_v2 alone -- which makes `npm run lint` and `lefthook run ci` unusable locally. The pre-commit hook is worse: it runs `prettier --write .` with stage_fixed, so any commit made from Windows rewrites and stages the whole client tree. Set `endOfLine: "auto"` in both client configs. Git still normalizes to LF in the index and in the repo thanks to `text=auto`, and CI runs on ubuntu-latest, so LF in version control is unaffected; prettier just stops fighting the checkout. This is Prettier's documented fix for this scenario. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>