mirror of
https://github.com/nix-community/home-manager
synced 2024-11-23 11:39:46 +01:00
firefox: make package nullable (#4113)
This commit is contained in:
parent
0306d5ed7e
commit
ba2c0737cc
1 changed files with 3 additions and 2 deletions
|
@ -137,7 +137,7 @@ in {
|
|||
enable = mkEnableOption "Firefox";
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
type = with types; nullOr package;
|
||||
default = if versionAtLeast config.home.stateVersion "19.09" then
|
||||
pkgs.firefox
|
||||
else
|
||||
|
@ -158,6 +158,7 @@ in {
|
|||
The Firefox package to use. If state version ≥ 19.09 then
|
||||
this should be a wrapped Firefox package. For earlier state
|
||||
versions it should be an unwrapped Firefox package.
|
||||
Set to <literal>null</literal> to disable installing Firefox.
|
||||
'';
|
||||
};
|
||||
|
||||
|
@ -526,7 +527,7 @@ in {
|
|||
cfg.package.override (old: { cfg = old.cfg or { } // fcfg; })
|
||||
else
|
||||
(pkgs.wrapFirefox.override { config = bcfg; }) cfg.package { };
|
||||
in [ package ];
|
||||
in lib.optional (cfg.package != null) package;
|
||||
|
||||
home.file = mkMerge ([{
|
||||
"${firefoxConfigPath}/profiles.ini" =
|
||||
|
|
Loading…
Reference in a new issue