1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-12-05 16:41:04 +01:00

firefox: don't show migration warning when bookmarks isn't set (#6689)

This commit is contained in:
Kira Bruneau 2025-03-23 19:13:55 -04:00 committed by GitHub
parent 4f4538467f
commit ad0614a1ec
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -383,27 +383,31 @@ in {
bookmarks = mkOption { bookmarks = mkOption {
type = (with types; type = (with types;
coercedTo bookmarkTypes.settingsType (bookmarks: coercedTo bookmarkTypes.settingsType (bookmarks:
warn '' if bookmarks != { } then
${cfg.name} bookmarks have been refactored into a submodule that now explicitly require a 'force' option to be enabled. warn ''
${cfg.name} bookmarks have been refactored into a submodule that now explicitly require a 'force' option to be enabled.
Replace: Replace:
${moduleName}.profiles.${name}.bookmarks = [ ... ]; ${moduleName}.profiles.${name}.bookmarks = [ ... ];
With: With:
${moduleName}.profiles.${name}.bookmarks = { ${moduleName}.profiles.${name}.bookmarks = {
force = true;
settings = [ ... ];
};
'' {
force = true; force = true;
settings = [ ... ]; settings = bookmarks;
}; }
'' { else
force = true; { }) (submodule ({ config, ... }:
settings = bookmarks; import ./profiles/bookmarks.nix {
}) (submodule ({ config, ... }: inherit config lib pkgs;
import ./profiles/bookmarks.nix { modulePath = modulePath
inherit config lib pkgs; ++ [ "profiles" name "bookmarks" ];
modulePath = modulePath ++ [ "profiles" name "bookmarks" ]; })));
})));
default = { }; default = { };
internal = !enableBookmarks; internal = !enableBookmarks;
description = "Declarative bookmarks."; description = "Declarative bookmarks.";