password-store: improve warning message

This commit is contained in:
Léana 江
2026-05-23 13:19:27 +02:00
committed by Austin Horstman
parent 68227a9363
commit f15c764b14
3 changed files with 7 additions and 7 deletions

View File

@@ -23,7 +23,7 @@ let
value = {
PASSWORD_STORE_DIR = "${config.xdg.dataHome}/password-store";
};
text = ''{ PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; }'';
text = ''{ PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; }'';
};
current.value = { };
deferWarningToConfig = true;

View File

@@ -5,10 +5,10 @@
test.asserts.warnings.expected = [
''
The default value of `programs.password-store.settings` has changed from `{ PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; }` to `{ }`.
You are currently using the legacy default (`{ PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; }`) because `home.stateVersion` is less than "25.11".
The default value of `programs.password-store.settings` has changed from `{ PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; }` to `{ }`.
You are currently using the legacy default (`{ PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; }`) because `home.stateVersion` is less than "25.11".
To silence this warning and keep legacy behavior, set:
programs.password-store.settings = { PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; };
programs.password-store.settings = { PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; };
To adopt the new default behavior, set:
programs.password-store.settings = { };
''

View File

@@ -10,10 +10,10 @@
test.asserts.warnings.expected = [
''
The default value of `programs.password-store.settings` has changed from `{ PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; }` to `{ }`.
You are currently using the legacy default (`{ PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; }`) because `home.stateVersion` is less than "25.11".
The default value of `programs.password-store.settings` has changed from `{ PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; }` to `{ }`.
You are currently using the legacy default (`{ PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; }`) because `home.stateVersion` is less than "25.11".
To silence this warning and keep legacy behavior, set:
programs.password-store.settings = { PASSWORD_STORE_DIR = "$XDG_DATA_HOME/password-store"; };
programs.password-store.settings = { PASSWORD_STORE_DIR = "''${config.xdg.dataHome}/password-store"; };
To adopt the new default behavior, set:
programs.password-store.settings = { };
''