# Text files are stored and checked out with LF on every platform. Git for
# Windows defaults to core.autocrlf=true, which would otherwise check out CRLF;
# the image build copies docker/ as checked out, and jq, Python and the shell
# in the container read CRLF as part of the program. Binary files are detected
# and left alone. The rules below override this for files that need CRLF.
*           text=auto eol=lf

# Keep shell scripts LF even on Windows checkouts. Git for Windows defaults to
# core.autocrlf=true, which would otherwise rewrite *.sh with CRLF on clone; CRLF
# in a script breaks `#!/bin/bash` and string comparisons under MSYS2/Git Bash,
# and these .sh files are run on Windows via scripts\scan-sbom.bat (Git Bash).
*.sh        text eol=lf
build-prep  text eol=lf
entrypoint  text eol=lf

# Programs and data the image reads on Linux: LF whatever text=auto decides.
*.jq        text eol=lf
*.py        text eol=lf
*.js        text eol=lf
*.mjs       text eol=lf
*.ts        text eol=lf
*.tsx       text eol=lf
*.txt       text eol=lf
*.toml      text eol=lf
*.yml       text eol=lf
*.yaml      text eol=lf
*.html      text eol=lf
*.css       text eol=lf
Dockerfile  text eol=lf

# Windows batch wrappers must stay CRLF.
*.bat       text eol=crlf

# PowerShell scripts: keep CRLF. The file carries a UTF-8 BOM so Windows
# PowerShell 5.1 (the default on Korean Windows) reads non-ASCII string
# literals as UTF-8 instead of the CP949 ANSI codepage; without the BOM the
# Korean text mangles and the script fails to parse.
*.ps1       text eol=crlf

# Fixtures / data are normalized to LF for byte-stable diffs across platforms.
*.json      text eol=lf
*.tsv       text eol=lf
*.md        text eol=lf
