colgreen / Redzen

General purpose C# code library.
Other
95 stars 16 forks source link

Define EnableNETAnalyzers in csproj files #16

Closed colgreen closed 3 years ago

colgreen commented 3 years ago

See: EnableNETAnalyzers

I think these can replace the current stylecop analyzers, i.e., this section in the csproj:

  <ItemGroup>
    <PackageReference Include="StyleCop.Analyzers" Version="1.1.118">
      <PrivateAssets>all</PrivateAssets>
      <IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
    </PackageReference>
  </ItemGroup>
colgreen commented 3 years ago

Closing, as this setting is on by default for .NET 5 projects (which redzen is now), and these two anaylzers are defined on the project by default (in addition to the stylecop analyzers that we add explicitly):