diff options
Diffstat (limited to 'modules/system/btop/assertions.nix')
| -rw-r--r-- | modules/system/btop/assertions.nix | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/modules/system/btop/assertions.nix b/modules/system/btop/assertions.nix new file mode 100644 index 0000000..82cddc3 --- /dev/null +++ b/modules/system/btop/assertions.nix @@ -0,0 +1,14 @@ +# Validates btop sub-options require the main module to be enabled +{ config, ... }: +{ + assertions = [ + { + assertion = !config.system.btop.nvidia.enable || config.system.btop.enable; + message = "system.btop.nvidia.enable requires system.btop.enable."; + } + { + assertion = !config.system.btop.amd.enable || config.system.btop.enable; + message = "system.btop.amd.enable requires system.btop.enable."; + } + ]; +} |
