summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2018-09-24 14:34:50 +0200
committermakefu <github@syntax-fehler.de>2018-09-24 14:34:50 +0200
commit796ad2c5c8ed67a4ece5a78e8e9cd5e1fbfe4e9e (patch)
tree1ba723512daedfe32e6fc1a434cb5236280633df
parent49e0ae20c9ac96c3f2e12e0faf6d2bd7e9348d61 (diff)
ma state.mod: put activation logic into module
-rw-r--r--makefu/3modules/state.nix7
1 files changed, 7 insertions, 0 deletions
diff --git a/makefu/3modules/state.nix b/makefu/3modules/state.nix
index 461b90152..a87f438fe 100644
--- a/makefu/3modules/state.nix
+++ b/makefu/3modules/state.nix
@@ -6,4 +6,11 @@
description = "state which is currently scattered on the machine";
default = [];
};
+
+ config.system.activationScripts.state = lib.optionalString (config.state != []) ''
+ cat << EOF
+ This machine is burdened with state:
+ ${lib.concatMapStringsSep "\n" (d: "* ${d}") config.state}
+ EOF
+ '';
}