I have created 2 custom analyzer using template "Analyzer with Code Fix (.NET Standard)" in VS 2019. Each analyzer has different project, and package project as well. Also I have Common project with some common shared code that are using every analyzer.
To be more clear, Custom Analyzer solution looks like:
csproj file for analyzer (Analyzer1 and Analyzer2) is:
Producing Nuget is by Package csproj files, i.e. for Analyzer1 is:
When I produce nupkg file both dlls are in folder "analyzers\dotnet\cs":
- Analyzer1.dll or Analyzer2.dll
- Common.dll
I include Nuget packages in final project as:
When using those 2 analyzers, I got this situation:
Goal:I want to have independent analyzers that all uses some shared code from Common project. Everything works except showing Common.dll that are not actually analyzer but code that analyzer depends on.
QUESTION:Is it possible to hide Common.dll from Dependencies/Analyzers and only have separate analyzers (Analyzer1, Analyzer2...)?