#### Community support has been moved to https://github.com/cake-build/cake/discussions ####
anyone seen this error before ```Preparing to run build script...
Tools: /Users/runner/work/1/s/foldername/build/tools
Tools: /Users/runner/work/1/s/foldername/build/tools/Addins
Start testing Cake path.
Running build script...
& dotnet "/Users/runner/work/1/s/foldername/build/tools/Cake.CoreCLR/Cake.dll" .\foldername\build\build.cake --bootstrap
Error: An exception was thrown while activating Cake.Commands.BootstrapCommand -> Cake.Core.Scripting.Analysis.ScriptAnalyzer -> λ:Cake.Core.Scripting.Processors.Loading.ILoadDirectiveProvider[] -> Cake.NuGet.NuGetLoadDirectiveProvider -> Cake.NuGet.Install.NuGetPackageInstaller.
```
Error: Autofac.Core.DependencyResolutionException: An exception was thrown while activating Cake.Commands.BootstrapCommand -> Cake.Core.Scripting.Analysis.ScriptAnalyzer -> λ:Cake.Core.Scripting.Processors.Loading.ILoadDirectiveProvider[] -> Cake.NuGet.NuGetLoadDirectiveProvider -> Cake.NuGet.Install.NuGetPackageInstaller. ---> Autofac.Core.DependencyResolutionException: An exception was thrown while invoking the constructor 'Void .ctor(Cake.Core.IO.IFileSystem, Cake.Core.ICakeEnvironment, Cake.NuGet.INuGetContentResolver, Cake.Core.Diagnostics.ICakeLog, Cake.Core.Configuration.ICakeConfiguration)' on type 'NuGetPackageInstaller'. ---> System.IO.FileNotFoundException: NuGet Config file not found.
at Cake.NuGet.Install.NuGetPackageInstaller.GetNuGetConfigPath(ICakeEnvironment environment, ICakeConfiguration config, IFileSystem fileSystem) in C:\projects\cake\src\Cake.NuGet\Install\NuGetPackageInstaller.cs:line 338
at Cake.NuGet.Install.NuGetPackageInstaller..ctor(IFileSystem fileSystem, ICakeEnvironment environment, INuGetContentResolver contentResolver, ICakeLog log, ICakeConfiguration config) in C:\projects\cake\src\Cake.NuGet\Install\NuGetPackageInstaller.cs:line 77
at lambda_method(Closure , Object[] )
at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
--- End of inner exception stack trace ---
at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters)
at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters, Object& decoratorTarget)
--- End of inner exception stack trace ---
at Autofac.Core.Resolving.InstanceLookup.Activate(IEnumerable`1 parameters, Object& decoratorTarget)
at Autofac.Core.Resolving.InstanceLookup.Execute()
at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, IComponentRegistration registration, IEnumerable`1 parameters)
at Autofac.Core.Resolving.ResolveOperation.Execute(IComponentRegistration registration, IEnumerable`1 parameters)
at lambda_method(Closure )
at Cake.CakeApplication.Run(CakeOptions options) in C:\projects\cake\src\Cake\CakeApplication.cs:line 45
at Cake.Program.Main() in C:\projects\cake\src\Cake\Program.cs:line 74
AzurePipelines.Commands.SetVariable()
with a unique variable name for each of these executions. I could do this with the same variable name, just where isOutput=true
. Then I could name the 3 cake script executions and refer them like: $(ios.releaseData)
, $(android.releaseData)
etc., instead.
Error: One or more errors occurred. (The specified executable is not a valid application for this OS platform.)
The specified executable is not a valid application for this OS platform.
StartProcess
call.
@/all A quick reminder that we suggest to use GitHub discussions as prefered communication channel. GitHub discussions makes it easier to keep track of discussions in a structured way, especially if multiple discussions are happening at the same time. It also allows to search for previous discussion, which can be a helpful resource. GitHub discussions should be a place for the community like here, and we would be more than happy if community would chime in to discussions over there.
We won't delete this channel, but discussions might move to the new place which is available at: https://github.com/cake-build/cake/discussions
dotnet add package ...
here: https://cakebuild.net/dsl/dotnetcore/#NuGet?
StartProcess("dotnet", new ProcessSettings { Arguments = argumentsBuilder, WorkingDirectory = workingDirectory })
? Why so? :)
Looking for input / feedback...
I have a lightweight test framework I call tclite. It's somewhat modelled after NUnit and NUnitLite, but with some differences. One use I have for it is to write tests in my cake scripts. For me, these are mostly system tests, which create output in XML format. I could, of course, have a separate test assembly to verify the format of the output, but I found it more convenient that my tests should live in the scripts themselves.
Currently, my mini-test-framework lives in a set of .cake
files but it could be in a separate assembly referenced by the script.
So... questions...
I suggest short answers here, longer via my email, which is my name here on gmail.
@CharliePoole We have question how to implement tests in Cake scripts from time to time here, so I assume something like this would be useful for some people.
Btw we started to use mainly GitHub discussions instead of this Gitter channel.
You might want to post there too for better coverage.
.cake
files as NuGet packages. It's what we call Recipe NuGet packages