From 3e2116f153077186556c01ae1fc89923abfea265 Mon Sep 17 00:00:00 2001 From: tv Date: Sat, 14 Nov 2026 03:45:10 +0000 Subject: populate: passage sources default identities_file when populate runs The default, toString ~/.passage/identities, is a path relative to the home directory, which Nix resolves when parsing the file defining it, populate's Nix library's types, so evaluating any sources failed in pure mode, e.g. in a flake. identities_file defaults to null, which leaves it out of the sources, and populate defaults it to ~/.passage/identities, in HOME, when it runs. The passage scenarios also run without identities_file, with HOME a directory that has .passage/identities. --- pkgs/populate/lib/types/populate.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'pkgs/populate/lib/types') diff --git a/pkgs/populate/lib/types/populate.nix b/pkgs/populate/lib/types/populate.nix index 56b0292..8e74c5e 100644 --- a/pkgs/populate/lib/types/populate.nix +++ b/pkgs/populate/lib/types/populate.nix @@ -294,9 +294,11 @@ dir = lib.mkOption { type = lib.types.pathname; }; + # Populate defaults to ~/.passage/identities when it runs, which + # evaluation can't tell in pure mode. identities_file = lib.mkOption { - default = toString ~/.passage/identities; - type = lib.types.pathname; + default = null; + type = lib.types.nullOr lib.types.pathname; }; }; }; -- cgit v1.3.1