maintainers/scripts/check-hydra-by-maintainer: ctrl-c fully exit
Currently ctrl-c while shellHook is running will drop you inside the nix-shell. This change catches ctrl-c and exits the same way.
This commit is contained in:
@@ -63,6 +63,12 @@ pkgs.stdenvNoCC.mkDerivation {
|
||||
command = "hydra-check ${lib.escapeShellArgs packages}";
|
||||
in
|
||||
''
|
||||
# if user presses ctrl-c during run
|
||||
# pass on ctrl-c to fully quit rather than exiting to nix-shell
|
||||
function ctrl_c() {
|
||||
exit 130
|
||||
}
|
||||
trap ctrl_c INT
|
||||
echo "Please stand by"
|
||||
echo "${command}"
|
||||
${command}
|
||||
|
||||
Reference in New Issue
Block a user