-
Notifications
You must be signed in to change notification settings - Fork 161
Expand file tree
/
Copy pathDirectory.Solution.targets
More file actions
26 lines (23 loc) · 1.64 KB
/
Directory.Solution.targets
File metadata and controls
26 lines (23 loc) · 1.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<Project>
<!-- Import the NuGet props file to get access to Pkg* variables -->
<Import Project="src/FSharp.Formatting/obj/FSharp.Formatting.fsproj.nuget.g.props" Condition="Exists('src/FSharp.Formatting/obj/FSharp.Formatting.fsproj.nuget.g.props')" />
<ItemGroup>
<ProjectsToAnalyze Include="src/**/*.fsproj" />
</ItemGroup>
<Target Name="AnalyzeSolution" Condition="Exists('src/FSharp.Formatting/obj/FSharp.Formatting.fsproj.nuget.g.props')">
<PropertyGroup>
<CodeRoot>$(SolutionDir)</CodeRoot>
<FSharpAnalyzersOtherFlags>--analyzers-path "$(PkgG-Research_FSharp_Analyzers)/analyzers/dotnet/fs"</FSharpAnalyzersOtherFlags>
<FSharpAnalyzersOtherFlags>$(FSharpAnalyzersOtherFlags) --analyzers-path "$(PkgIonide_Analyzers)/analyzers/dotnet/fs"</FSharpAnalyzersOtherFlags>
<FSharpAnalyzersOtherFlags>$(FSharpAnalyzersOtherFlags) --exclude-analyzers PartialAppAnalyzer ReturnStructPartialActivePatternAnalyzer -c Release</FSharpAnalyzersOtherFlags>
<FSharpAnalyzersOtherFlags>$(FSharpAnalyzersOtherFlags) --code-root $(CodeRoot)</FSharpAnalyzersOtherFlags>
<FSharpAnalyzersOtherFlags>$(FSharpAnalyzersOtherFlags) --report "$(CodeRoot)/analysis.sarif"</FSharpAnalyzersOtherFlags>
</PropertyGroup>
<Delete Files="$(SolutionDir)/analysis.sarif" Condition="Exists('$(SolutionDir)/analysis.sarif')" />
<!-- Execute fsharp-analyzers with all projects in a single process -->
<Exec
Command="dotnet fsharp-analyzers $(FSharpAnalyzersOtherFlags) @(ProjectsToAnalyze->'--project "%(FullPath)"', ' ')"
ContinueOnError="true"
/>
</Target>
</Project>