dotnet build /p:ContinuousIntegrationBuild=true doesn't work
See original GitHub issue(I hope this is the correct place to raise this question/issue. apologies if it isn’t)
Issue
Trying to building a class library on a CI/CD server that is deterministic using the ContinuousIntegrationBuild=true
property argument on the cli doesn’t seem to actually do this?
Assumption:
dotnet build
should allow this msbuild property- I can build/confirm this on my localhost development machine for testing, before it is ‘pushed up’ to a CI server.
Steps to repo.
- mkdir deterministic-nuget
- cd deterministic-nuget
- dotnet new classlib
- dotnet build -c RELEASE /p:ContinuousIntegrationBuild=true -p:version=1.2.3-pre.1
- dotnet pack -c RELEASE --no-build -p:packageVersion=1.2.3-pre.1 -o C:\temp\nuget-testing\
now goto C:\temp\nuget-testing
and double click on the .nupkg
file that is there. NuGet Package Explorer opens up and this is what it looks like:
I’m not sure if this is an issue with NuGet or dotnet build
CLI or NGPE?
Info
- On my own windows 10 dev machine.
❯ dotnet --info
.NET SDK (reflecting any global.json):
Version: 5.0.201
Commit: a09bd5c86c
Runtime Environment:
OS Name: Windows
OS Version: 10.0.19042
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\5.0.201\
Host (useful for support):
Version: 5.0.4
Commit: f27d337295
.NET SDKs installed:
2.2.207 [C:\Program Files\dotnet\sdk]
3.1.406 [C:\Program Files\dotnet\sdk]
5.0.100 [C:\Program Files\dotnet\sdk]
5.0.201 [C:\Program Files\dotnet\sdk]
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:33 (7 by maintainers)
Top Results From Across the Web
Build Fails with "Error:The process '/usr/bin/dotnet' failed ...
The CI pipeline works well if I remove the nobuild:true option from the DotNetCoreCLI@2 task to pack the Project (ie to create a...
Read more >dotnet build command - .NET CLI
The dotnet build command builds a project and all of its dependencies.
Read more >Use the .NET SDK in Continuous Integration (CI) ...
This article outlines how to use the .NET SDK and its tools on a build server. The .NET toolset works both interactively, where...
Read more >dotnet publish command - .NET CLI
dotnet publish - Publishes the application and its dependencies to a folder for deployment to a hosting system.
Read more >dotnet test command - .NET CLI
The dotnet test command builds the solution and runs a test host application for each test project in the solution. The test host...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I noticed that paths were getting ‘normalized’ when I build a project with Microsoft.SourceLink.GitLab package installed and as soon as I uninstalled SourceLink, ContinuousIntegrationBuild=true has no effect. Didn’t have time to attempt debugging.
I’ve just hit this too on https://github.com/DamianEdwards/MinimalValidation. I haven’t been able to workaround it by being explicit when calling
dotnet pack
either.