From 818207b99b6df30becc515d20f4ffc2da3300a64 Mon Sep 17 00:00:00 2001 From: rogarb Date: Fri, 21 Jul 2023 18:45:22 +0200 Subject: [PATCH] fix(btrfs): add warning for subvolume mounts --- lib/types/btrfs.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/types/btrfs.nix b/lib/types/btrfs.nix index 3c9aa8f..48af13c 100644 --- a/lib/types/btrfs.nix +++ b/lib/types/btrfs.nix @@ -91,6 +91,8 @@ let subvolMounts = lib.concatMapAttrs (_: subvol: + lib.warnIf (subvol.mountOptions != (options.subvolumes.type.getSubOptions []).mountOptions.default && subvol.mountpoint == null) + "Subvolume ${subvol.name} has mountOptions but no mountpoint. See upgrade guide (2023-07-09 121df48)." lib.optionalAttrs (subvol.mountpoint != null) { ${subvol.mountpoint} = '' if ! findmnt ${config.device} "${rootMountPoint}${subvol.mountpoint}" > /dev/null 2>&1; then