Skip to content

Commit

Permalink
Allowed a source generator option to avoid adding a dependency to the…
Browse files Browse the repository at this point in the history
… library.
  • Loading branch information
MarkCiliaVincenti committed Nov 17, 2024
1 parent 2092e78 commit 8a9b6d5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,10 +157,12 @@ to:

Therefore in the clean method (if only targeting .NET 5.0 or greater):

```csharp
<PackageReference Condition="!$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'net9.0'))" Include="Backport.System.Threading.Lock" Version="3.0.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>analyzers</IncludeAssets>
</PackageReference>
```

and in the factory method (if targeting frameworks prior to .NET 5.0):

Expand Down

0 comments on commit 8a9b6d5

Please sign in to comment.