https://pulumi.com logo
Title
w

witty-vegetable-61961

12/15/2022, 11:01 PM
hi all, is there a way to use Pulumi with sln files? I want a project iwht an sln file as NDepend requires an sln file.
i

icy-doctor-13719

12/16/2022, 12:00 AM
its a
.csproj
so i don’t see why not 🙂
e

echoing-dinner-19531

12/16/2022, 8:26 AM
https://github.com/pulumi/pulumi-dotnet/issues/55 You can have a top level .sln and tell pulumi which .csproj is the one to use for infra by setting "main" in Pulumi.yaml.
w

witty-vegetable-61961

12/16/2022, 1:43 PM
ah I should have said, i had a test project with an sln file and I tried the approach oiwth the main entry point but it would still complain.
On v3.49.0 btw
Ok so with the workaround, Pulumi then complains there is more than 1 project file. However, I use NDepend for static analysis, which has a NDProj file format for its project file. Pulumi seems to think this is a project file for C#, presumably due to the suffix, so this logic needs changing. I moved the file into a folder and the build works now.