Build automation system based on C#
Questions tagged [nuke-build]
30 questions
7
votes
2 answers
How to install dotnet tool with nuke
I am new to Nuke, trying to transition from Cake to Nuke.
In Cake I have the option to install (locally) tools with:
#module nuget:?package=Cake.DotNetTool.Module&version=0.3.0
and
#tool dotnet:?package=my.package.id&version=1.0.1
I have tried…

TheRoadrunner
- 1,281
- 14
- 34
4
votes
1 answer
How to use VSTest from Nuke builds
I am trying to use Nuke to run VSTest as some of my tests are in .Net Framework (not core).
I have a test running succesfully with:
VSTest(@".\test\MyTestProjectFolder\bin\Debug\net47\MyTestProject.dll");
...but I don't like to point into the…

TheRoadrunner
- 1,281
- 14
- 34
3
votes
2 answers
How to publish solution in nuke-build using msBuild
This might be a lame question, maybe I'm missing something very obvious. But I'm trying to solve this for a few days now without success.
I have quite a huge solution (31 projects) that uses .NET framework. We used to use CAKE build for build and…

Martin Trampus
- 133
- 1
- 10
3
votes
1 answer
How to pass Azure Auth when Deploying NuGet Package via Nuke.Common/NuGet.CommandLine
I'm attempting to automate NuGet Package updates through Nuke and CI/CD on Azure DevOps. Everything is building just fine, but during the PushNuGet step, the process tries to authenticate with Azure via a pop-up window, which is obviously never…

Chris Phillips
- 1,997
- 2
- 19
- 34
3
votes
3 answers
How to get the OutputPath of a project in a Nuke build
I'm adding a Nuke build project to my solution.
I need to create a target which copies the compiled files to a custom folder. You can think of it as a sort of deploy.
How do I get the output folder of a specific project?
For example, if the project…

Paolo Fulgoni
- 5,208
- 3
- 39
- 55
3
votes
3 answers
Nuke build .nuke file and build multiple solutions
I am using nuke build for the first time.
Working through the getting started guide, I have ran the following:
dotnet tool install Nuke.GlobalTool --global
nuke :setup
This ran through a wizard which generated:
build folder containing a csharp…

Andez
- 5,588
- 20
- 75
- 116
2
votes
1 answer
How to find and use methods for DotNetRestore, DotNetBuild etc in Nuke.Build 6.2.1
I'm trying to learn how to use Nuke.build but I'm having trouble right from the start.
I've followed the documentation and added a nuke project to my solution by typing nuke and following the prompts.
I now have three empty targets in…

Dan McCoy
- 313
- 2
- 15
2
votes
1 answer
Using Nuke build to push a tag to an Azure Devops repository
I'm trying to figure out how to push a tag after a successful build back to the azure devops git repository. Whether I'm just asking the wrong questions or going about it wrong I'm just not sure, but I am at the point where I'd better reach out for…

Toadicus Rex
- 35
- 1
- 6
2
votes
0 answers
How to connect to Docker SQL Server in GitHub Actions
I am trying to automate my testing using Nuke Build on GitHub. I am using a Docker to run a SQL Server container for testing. When it is run by GitHub Actions this error occurs. The image is successfully created and the error occurs when the tests…

i-will-lie
- 21
- 4
2
votes
1 answer
Nuke Build declare a tool that is fetched as part of the build
Most of the tools I use, are dotnet tools that are referenced from csproj file and automagically fetched by nuget.
A few tools are old-school Framework tools, which should be copied into the tools directory before use.
For the latter I have a…

TheRoadrunner
- 1,281
- 14
- 34
1
vote
1 answer
How do I set a variable with Nuke to use it in a GitHub Actions matrix afterwards?
I am currently working my way into GitHub Actions as well as NUKE.build.
My project consists of 2 jobs in GitHub Actions:
The first job is responsible for reading the build configurations from a given .csproj file and setting it as a JSON array…

CaptTaifun
- 321
- 5
- 15
1
vote
0 answers
Need help moving MSBuild to Nuke
I'm trying to replace MSBuild with nuke, but I'm having trouble doing so. The first thing that I tried to do is setting the intermediate output paths and whatnot to another folder. I have previously done this in MSBuild by using a props file that…

Anton Curmanschii
- 339
- 2
- 16
1
vote
2 answers
NUKE Build in Azure DevOps Build Pipeline Failing
So I have implemented the NUKE build system in my solution, and everything 100% works locally.
Out in Azure DevOps it's a different story, my YAML task looks like this:
- task: CmdLine@2
displayName: 'NUKE Build'
inputs:
script:
…

Xorcist
- 3,129
- 3
- 21
- 47
1
vote
1 answer
Nuke Build in the Docker Image for .Net Core SDK and AspNetCore
I have a .net core 3.1 API that uses Nuke Build to run tests and build the application.
we have created a Nuke task to run the dockerfile for this application.
We want to create an image with .Net/Asp.Net and Nuke Build in order to use this image to…

user428745
- 803
- 1
- 8
- 12
0
votes
0 answers
Sharing state between Targets
Is it possible to share state between Targets in Nuke?
Lets say I wanted this scenerario.
class Build : NukeBuild {
public static int Main () => Execute(x => x.Clean);
Target Clean => _ => _
.Executes(() =>
{
…

dvan123
- 33
- 5