Commit 71adea2
Fix CRLF line endings by adding eol=lf to .gitattributes (#212)
## Description
Adds `eol=lf` to the catch-all `.gitattributes` rule, changing it from:
```
* text=auto
```
to:
```
* text=auto eol=lf
```
Without `eol=lf`, the checkout line ending falls back to the user's
`core.autocrlf` setting. Users with `core.autocrlf=true` (common in
dotfiles synced from Windows setups) will check out files with CRLF even
on Linux/macOS/Codespaces, which can cause CRLF to appear in PRs.
Adding `eol=lf` explicitly overrides `core.autocrlf` at the repo level,
ensuring LF checkout for everyone regardless of their global git config.
All tracked files were renormalized via `git add --renormalize .` — 5
files had latent CRLF that was cleaned up.
## How was this tested
- Ran `git add --renormalize .` to verify which files were affected
- Confirmed the commit diff shows CRLF → LF normalization in the
affected files
## Type of change
- [x] Bug fix
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 1afc2bb commit 71adea2
8 files changed
Lines changed: 2241 additions & 2231 deletions
File tree
- api/spfx-template-api
- etc
- src
- templating
- test
- writing/test
- apps/spfx-cli/src/cli/actions
- common/changes/@microsoft/spfx-cli
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
0 commit comments