Open ByteDev opened 1 year ago
解决了吗,我也碰到此问题,cake4.0
I had the same issue with Cake.powershell 3.0.0 The package requires system.automation.7.3.3 and it has one of the dll missing
Hi there!
That's an interesting bug and it would be great if someone could solve it for good. But it might not be an easy one.
I have created a dummy test project to reproduce the bug. It is available in a separate repository.
This allowed me to find a workaround for this bug. Feel free to try it out.
In a few words:
[NuGet]
LoadDependencies=true
#addin nuget:?package=Cake.Powershell&version=3.0.0
#addin nuget:?package=Microsoft.PowerShell.Commands.Management&version=7.4.3
This bug seems to be resolved with Cake.PowerShell 4.0.0.
All you need to do is add Cake.PowerShell 4.0.0 as add-in with dependencies.
#addin nuget:?package=Cake.Powershell&version=4.0.0&loaddependencies=true
The &loaddependencies=true
is required!
I was under the impression from the Cake Powershell page that Cake 2.0.0 is supported but when I run:
dotnet cake build.cake
I get the following error:I'm referencing Cake.Powershell via an addin in my cake file:
#addin nuget:?package=Cake.Powershell&version=2.0.0
.Any idea of the problem? Any plans for Cake 3.0.0 support? Thanks