Skip to content

Fix IDE0055 errors in Windows checkouts - #10520

Merged
glen-84 merged 3 commits into
ChilliCream:mainfrom
PHILLIPS71:jp/gitattributes-eol-lf
Oct 9, 2026
Merged

glen-84 merged 3 commits into
ChilliCream:mainfrom
PHILLIPS71:jp/gitattributes-eol-lf

Conversation

@PHILLIPS71

Copy link
Copy Markdown
Contributor

Git for Windows defaults to core.autocrlf=true, which checks files out with CRLF. .editorconfig sets end_of_line = lf and EnforceCodeStyleInBuild makes IDE0055 a build error, so Windows contributors get formatting errors in files they never touched.

For example, in a file that is unchanged from main:

ExpressionHelpers.cs(281,51): error IDE0055: Fix formatting

dotnet format whitespace --verify-no-changes shows the only difference is CRLF vs LF. The indentation is identical. Only some lines fail, because the formatter only checks newlines it rewrites.

This sets eol=lf so checkouts use LF regardless of local Git config. text=auto still leaves binary files alone, and the eol=crlf rules for .bat, .cmd and .ps1 still apply because they come later in the file.

@glen-84 glen-84 changed the title fix(git): check out text files with LF line endings Fix IDE0055 errors in Windows checkouts Oct 9, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No unresolved review comments remain.

0 open findings

What changed in this PR

Configures Git checkout line endings to prevent Windows IDE0055 errors while preserving CRLF for Windows scripts.

Changes:

  • Sets text files to LF.
  • Retains CRLF rules for .bat, .cmd, and .ps1.
File Description
.gitattributes Enforces consistent checkout line endings.

🧠 Review effort: Lite


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@glen-84
glen-84 merged commit 0884e86 into ChilliCream:main Oct 9, 2026
152 checks passed
@PHILLIPS71
PHILLIPS71 deleted the jp/gitattributes-eol-lf branch October 9, 2026 20:52
This was referenced Nov 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants