Enable state-version in defaults

This commit is contained in:
pinpox
2025-08-12 12:23:45 +02:00
committed by pinpox
parent 22cd9baee2
commit 4934884e0c
2 changed files with 7 additions and 2 deletions

View File

@@ -8,6 +8,10 @@
{
imports = lib.optional (_class == "nixos") (
lib.mkIf config.clan.core.enableRecommendedDefaults {
# Enable automatic state-version generation.
clan.core.settings.state-version.enable = true;
# Use systemd during boot as well except:
# - systems with raids as this currently require manual configuration: https://github.com/NixOS/nixpkgs/issues/210210
# - for containers we currently rely on the `stage-2` init script that sets up our /etc
@@ -37,6 +41,7 @@
};
config = lib.mkIf config.clan.core.enableRecommendedDefaults {
# This disables the HTML manual and `nixos-help` command but leaves
# `man configuration.nix`
documentation.doc.enable = lib.mkDefault false;

View File

@@ -198,7 +198,7 @@ def test_generate_public_and_secret_vars(
assert check_vars(machine.name, machine.flake)
# get last commit message
commit_message = run(
["git", "log", "-5", "--pretty=%B"],
["git", "log", "-6", "--pretty=%B"],
).stdout.strip()
assert (
"Update vars via generator my_generator for machine my_machine"
@@ -878,7 +878,7 @@ def test_api_set_prompts(
# get_generators should bind the store
assert generators[0].files[0]._store is not None
assert len(generators) == 1
assert len(generators) == 2
assert generators[0].name == "my_generator"
assert generators[0].prompts[0].name == "prompt1"
assert generators[0].prompts[0].previous_value == "input2"