# ============================================================
# .gitattributes (Keep files consistent across operating systems)
# ============================================================

# REQ.UNIVERSAL: All professional GitHub project repositories MUST include .gitattributes.
# WHY: Ensure consistent line endings, diff behavior, and file classification
# across Windows, macOS, and Linux environments.
# ALT: Repository may omit .gitattributes ONLY if equivalent normalization is
# enforced reliably by tooling and CI (rare and fragile).
# CUSTOM: Update file-type rules only when introducing new languages,
# binary artifacts, or documentation formats.
# NOTE: Rules are ordered by impact and generality, not alphabetically.
# Git attributes are documented at https://git-scm.com/docs/gitattributes

# === Core defaults (always apply) ===

# WHY: Auto-detect text files and normalize line endings to avoid cross-platform drift.
* text=auto

# WHY-SECTION: Explicit EOL rules avoid platform-specific diffs and tool failures.

# === Scripts ===
# Python and shell scripts must always use LF (CI, Linux, macOS, containers)
*.py  text eol=lf
*.sh  text eol=lf

# PowerShell scripts follow Windows convention
*.ps1 text eol=crlf

# === Docs and configs ===
# Cross-platform; tooling expects LF
*.md   text eol=lf
*.yaml text eol=lf
*.yml  text eol=lf
*.json text eol=lf
*.toml text eol=lf

# === GitHub Linguist ===
# Improve language statistics and UI without affecting builds
docs/** linguist-documentation

# Jupyter notebooks: custom diff/merge drivers (if configured)
*.ipynb diff=jupyternotebook
*.ipynb merge=jupyternotebook
