Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IDE0055 false positive with LF line endings (OSOE-344) #71

Open
sarahelsaig opened this issue May 12, 2022 · 2 comments
Open

IDE0055 false positive with LF line endings (OSOE-344) #71

sarahelsaig opened this issue May 12, 2022 · 2 comments
Labels
bug Something isn't working

Comments

@sarahelsaig
Copy link
Member

sarahelsaig commented May 12, 2022

This is our follow-up issue once dotnet/roslyn#55526 is fixed.

What's the problem?

In Git repositories, it's common to use LF (\n, "Unix-style") line endings for better cross-platform compatibility (see Lombiq/Open-Source-Orchard-Core-Extensions#65). The problem is that with .cs files, if we have LF line endings instead of CRLF (\r\n, "Windows-style") then roslyn will emit several false-positive IDE0055 warnings. There is a workaround of making only the .cs files CRLF as described in the above-linked issue. We have applied it to this repo and its submodules during OSOE-49.

What needs to be done?

Once the analyzer is fixed, the *.cs text eol=crlf rule should be removed from all .gitattributes files and then all .cs files should be renormalized to LF using the same steps described in the issue description of OSOE-91.

Jira issue

@Piedone Piedone added the bug Something isn't working label Aug 11, 2022
@Piedone Piedone transferred this issue from Lombiq/Open-Source-Orchard-Core-Extensions Aug 30, 2022
@github-actions github-actions bot changed the title IDE0055 false positive with LF line endings IDE0055 false positive with LF line endings (OSOE-344) Sep 18, 2022
@wAsnk
Copy link
Member

wAsnk commented Jan 25, 2023

It just happened in Lombiq/Hosting-Media-Theme#33

@Piedone
Copy link
Member

Piedone commented Aug 14, 2024

We could, or most possibly would need to, remove the end_of_line config from .editorconfig too:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants