Build scripts run build when passed only -pack
- Dominant language
- C#
- Stars
- 729
- Forks
- 397
- Avg merge
- 3d 15m
- Merged PRs (30d)
- 149
Description
- [ ] This issue is blocking
- [ ] This issue is causing unreasonable pain
When running `build -pack` without `-build`, we (correctly) avoid calling the `Build` target and call the `Pack` target
https://github.com/dotnet/arcade/blob/dc5339d8a7ddae9207e331a0400693cc2a0dcf59/src/Microsoft.DotNet.Arcade.Sdk/tools/Build.proj#L106-L110
But `Pack` depends on `Build` in normal operation, so this doesn't actually avoid building. In a repo like `dotnet/extensions` that has separate `build.cmd` invocations for build, test, and pack, the pack invocation can cause unexpected incremental builds.
`dotnet pack --no-build` passes an additional global property `NoBuild=true` to break the pack-to-build dependency, and I think `build.proj` should too.
Contributor guide
Assessment
This issue has not been assessed yet.