Skip to content

Commit

Permalink
Update template and readme (#670)
Browse files Browse the repository at this point in the history
* Update template and readme

fixes #669

* revert
  • Loading branch information
ErikEJ authored Dec 18, 2024
1 parent 7abd55e commit e5b2557
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 11 deletions.
24 changes: 18 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,14 @@ You should now have a project file with the following contents:
<ItemGroup>
<!-- These packages adds additional code analysis rules -->
<!-- We recommend using these, but they can be removed if desired -->
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.1" />
<PackageReference Include="ErikEJ.DacFX.TSQLSmellSCA" Version="1.1.1" />
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="ErikEJ.DacFX.TSQLSmellSCA" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>

<PropertyGroup>
Expand Down Expand Up @@ -587,10 +593,16 @@ We know of the following public rules NuGet packages, that you can add to your p
> These rule sets were included with the SDK in version 2.7.x and 2.8.x, but must be added explicitly with SDK version 2.9.x and later.
```xml
<ItemGroup>
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.1" />
<PackageReference Include="ErikEJ.DacFX.TSQLSmellSCA" Version="1.1.1" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="ErikEJ.DacFX.TSQLSmellSCA" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
```

They are based on these older repositories:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,14 @@
<ItemGroup>
<!-- These packages adds additional code analysis rules -->
<!-- We recommend using these, but they can be removed if desired -->
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.1" />
<PackageReference Include="ErikEJ.DacFX.TSQLSmellSCA" Version="1.1.1" />
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="ErikEJ.DacFX.TSQLSmellSCA" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>

<PropertyGroup>
Expand Down
9 changes: 6 additions & 3 deletions test/TestProjectWithAnalyzers/TestProjectWithAnalyzers.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,12 @@
<None Remove="Procedures\sp_TestUnsuppressed.sql" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.0" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ErikEJ.DacFX.SqlServer.Rules" Version="1.1.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>

<Import Project="$(MSBuildThisFileDirectory)..\..\src\MSBuild.Sdk.SqlProj\Sdk\Sdk.targets" />
</Project>

0 comments on commit e5b2557

Please sign in to comment.