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

Migrate to .editorconfig from ruleset files (OSOE-179) #32

Closed
6 tasks done
Piedone opened this issue Nov 11, 2021 · 4 comments · Fixed by #93
Closed
6 tasks done

Migrate to .editorconfig from ruleset files (OSOE-179) #32

Piedone opened this issue Nov 11, 2021 · 4 comments · Fixed by #93
Assignees
Labels
enhancement New feature or request

Comments

@Piedone
Copy link
Member

Piedone commented Nov 11, 2021

This is only suitable once .editorconfig has everything ruleset files provide already:

Tasks:

  • Migrate the config files, see the official docs.
  • Perhaps we need to have use case-specific packages, e.g. `Lombiq.Analyzers.OrchardCore"?
  • Update docs. Search for ".editorconfig" and "ruleset".
  • Add docs on migration, including converting ruleset files.
  • Check if we need <developmentDependency>true</developmentDependency> in the nuspec template. The analyzer packages we use do this. Check the generated <PackageReference> after a new install and change the docs, including release notes, and consuming projects if necessary.
  • Publish new NuGet package. This will need to be a major release. Add migration docs to the release.
@Piedone Piedone added the enhancement New feature or request label Nov 11, 2021
@Piedone Piedone changed the title Migrate to .editorconfig from ruleset files Migrate to .editorconfig from ruleset files (OSOE-179) Aug 30, 2022
@Piedone
Copy link
Member Author

Piedone commented Oct 4, 2023

Some notes:

  • <GlobalAnalyzerConfigFiles> and <EditorConfigFiles> seem to be virtually equivalent. Even if you use the latter and name your files something.editorconfig, they'll actually be global AnalyzerConfig files and need is_global = true. GlobalAnalyzerConfigFiles is meant to be used by us.
  • While .editorconfig files work solely based on the folder structure, .globalconfigs can do this and also be referenced with <GlobalAnalyzerConfigFiles>.
  • We could leave the editor-specific config, like charset, guidelines, tabs, in .editorconfig, which would remain copied. Analyzer configs would be moved to .globalconfigs, and would be referenced instead of copied.

@Piedone
Copy link
Member Author

Piedone commented Oct 10, 2023

We'll have a hard time getting the editor GUI working: dotnet/roslyn#70326

@Piedone
Copy link
Member Author

Piedone commented Oct 10, 2023

We need .NET 8 for this: dotnet/roslyn-analyzers#6281 (comment)

@Piedone
Copy link
Member Author

Piedone commented Oct 11, 2023

We don't need .NET 8, that's only when TreatWarningsAsErrors=false and CodeAnalysisTreatWarningsAsErrors=true but we don't do that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant