Skip to content

CSHARP-6189: Make the license headers, encoding and line endings uniform and enforce them in CI - #2096

Open
papafe wants to merge 6 commits into
mongodb:mainfrom
papafe:csharp6189
Open

papafe wants to merge 6 commits into
mongodb:mainfrom
papafe:csharp6189

Conversation

@papafe

@papafe papafe commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

https://jira.mongodb.org/browse/CSHARP-6189

This normalizes every header to a single banner with a uniform 2010 year, updates the Rider file templates to match, and adds a CI check so they cannot drift apart again. It also sets charset = utf-8 and end_of_line = lf for .cs files and normalizes the tree to match, so encoding and line endings are enforced by the dotnet format check we already run.

Nothing changes beyond license headers, the BOM and line endings. src/MongoDB.Driver/Authentication/SaslPrepHelper.cs is excluded, as Apache-2.0 section 4 requires retaining its dual-license attribution.

@papafe
papafe requested a review from a team as a code owner August 11, 2026 12:55
@papafe
papafe requested review from BorisDog and a lite review from Copilot August 11, 2026 12:55

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.

Copilot wasn't able to review this pull request because it exceeds the maximum number of files (300). Try reducing the number of changed files and requesting a review from Copilot again.

@papafe papafe added the maintenance Non-code maintenance (deps, docs, configs, etc.). label Aug 11, 2026
@papafe papafe changed the title CSHARP-6189: Make the license headers uniform and enforce them in CI CSHARP-6189: Make the license headers, encoding and line endings uniform and enforce them in CI Aug 18, 2026

@BorisDog BorisDog 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.

Look good overall.
dotnet format --verify-no-changes fails on windows because of the line endings.
We might want to switch to LF endings on windows as well, and to add something *.cs text eol=lf to .gitattributes. But let's discuss.

@papafe
papafe force-pushed the csharp6189 branch 2 times, most recently from 0762e26 to dbb59ce Compare October 9, 2026 09:43
@papafe
papafe requested a review from BorisDog October 9, 2026 11:04
@papafe

papafe commented Oct 9, 2026

Copy link
Copy Markdown
Contributor Author

Hey @BorisDog can you give a final look to this? So I can merge.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Non-code maintenance (deps, docs, configs, etc.).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants