diff --git a/hosts/common/programs/firefox.nix b/hosts/common/programs/firefox.nix index 744be195..a8dd50d0 100644 --- a/hosts/common/programs/firefox.nix +++ b/hosts/common/programs/firefox.nix @@ -326,7 +326,6 @@ in // matrix: for Nheko matrix client defaultPref("network.protocol-handler.external.matrix", true); ''; - fs."${cfg.browser.dotDir}/default".dir = {}; # instruct Firefox to put the profile in a predictable directory (so we can do things like persist just it). # XXX: the directory *must* exist, even if empty; Firefox will not create the directory itself. fs."${cfg.browser.dotDir}/profiles.ini".symlink.text = '' @@ -344,24 +343,23 @@ in env.PASSWORD_STORE_DIR = "/home/colin/knowledge/secrets/accounts"; # alternative to PASSWORD_STORE_DIR, but firejail doesn't handle this symlink well # fs.".password-store".symlink.target = lib.mkIf cfg.addons.browserpass-extension.enable "knowledge/secrets/accounts"; - }; - }) - (mkIf config.sane.programs.firefox.enabled { - # TODO: move the persistence into the sane.programs API (above) - # flush the cache to disk to avoid it taking up too much tmp. - sane.user.persist.byPath."${cfg.browser.cacheDir}".store = - if (cfg.persistData != null) then - cfg.persistData - else - "cryptClearOnBoot" + + # flush the cache to disk to avoid it taking up too much tmp. + persist.byPath."${cfg.browser.cacheDir}".store = + if (cfg.persistData != null) then + cfg.persistData + else + "cryptClearOnBoot" ; - sane.user.persist.byPath."${cfg.browser.dotDir}/default".store = - if (cfg.persistData != null) then - cfg.persistData - else - "cryptClearOnBoot" + persist.byPath."${cfg.browser.dotDir}/default".store = + if (cfg.persistData != null) then + cfg.persistData + else + "cryptClearOnBoot" ; + }; + }) ]; }