Closed qualitas-software closed 4 years ago
For anyone else who ends up here who is also using .NET Framework (4.7.2) & ASP.NET Core (2.2)...
I resolved this by making two changes:
In the .csproj file I changed:
<Exec Command="$(NSwagExe_Core22) run ... " >
to
<Exec Command="$(NSwagExe) run ... " >
And in the nswag.json, I change the runtime property to "WinX64"
I am trying to generate an OpenApi document for an ASP.NET Core 2.2 WebAPI that is set for target framework=net472, as part of MSBuild.
My .csproj file has the following relevant items, gleaned from the wikis :
<TargetFramework>net472</TargetFramework>
<PackageReference Include="Microsoft.AspNetCore" Version="2.2.0" />
<PackageReference Include="NSwag.MSBuild" Version="13.1.5">...
<Target Name="NSwag" AfterTargets="Build">...
When I do a build I get the following error/info reported in the Build window:
Additionally the nswag.json looks like this (top part only):
Any ideas what I need to adjust to make this work ?