From 48ed6f68b03f0a7a67915beeb233436e17e8eb2b Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Thu, 12 Sep 2024 19:02:33 +0200 Subject: [PATCH] Ensure partition script exits early on error --- lib/modules/partition/disks.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/modules/partition/disks.nix b/lib/modules/partition/disks.nix index 9e761b4d..3e651b78 100644 --- a/lib/modules/partition/disks.nix +++ b/lib/modules/partition/disks.nix @@ -346,6 +346,7 @@ (builtins.filter (_: _.useSwap) partitions)); in lib.strings.concatLines ([ "#!/bin/bash" + "set -o errexit" ] ++ (builtins.map (_: _.deviceScript) disks) ++ lib.optionals ((builtins.length disks) > 0) [