Is your feature request related to a problem? Please describe.
I remember a small quality of life feature that I miss from Yocto/Bitbake for interrupting a build.
Describe the solution you'd like
The first CTRL-C received will trigger a graceful stop which means no more derivation build will begin, but the in progress ones will complete before stopping the process.
Only the second CTRL-C received will force a shutdown (current Nix behavior).
Describe alternatives you've considered
Additional context
This is nice to have in context of cross compilation or tweaking with build flags, where there is no binary cache anymore and building a whole system can take several hours, with some huge derivations inside.
It is worth to complete a 75%-built LLVM before pausing the build, for example.
This sounds useful so we welcome a PR that implements this, though there might be UX interactions that should be considered (e.g. does it violate user expectations if Ctrl-C doesn't exit right away; what should happen in scripts, etc.).
Is your feature request related to a problem? Please describe.
I remember a small quality of life feature that I miss from Yocto/Bitbake for interrupting a build.
Describe the solution you'd like
The first CTRL-C received will trigger a graceful stop which means no more derivation build will begin, but the in progress ones will complete before stopping the process.
Only the second CTRL-C received will force a shutdown (current Nix behavior).
Describe alternatives you've considered
Additional context
This is nice to have in context of cross compilation or tweaking with build flags, where there is no binary cache anymore and building a whole system can take several hours, with some huge derivations inside. It is worth to complete a 75%-built LLVM before pausing the build, for example.
Priorities
Add :+1: to issues you find important.