home-manager: add force option for gtk-2 config (#7073)

This adds gtk.gtk2.force enable option which maps directly onto home.files.${cfg2.configLocation}.force to allow overwrite of the gtkrc-2.0 file (workaround for bug #6188).
This commit is contained in:
xezo360hye
2025-05-20 18:04:16 +03:00
committed by GitHub
parent 65d2282ff6
commit d3f5d870e3

View File

@@ -169,6 +169,8 @@ in
The location to put the GTK configuration file.
'';
};
force = lib.mkEnableOption "GTK 2 config force overwrite without creating a backup";
};
gtk3 = {
@@ -294,10 +296,14 @@ in
cfg.cursorTheme
];
home.file.${cfg2.configLocation}.text =
lib.concatMapStrings (l: l + "\n") (lib.mapAttrsToList formatGtk2Option gtkIni)
+ cfg2.extraConfig
+ "\n";
home.file.${cfg2.configLocation} = {
text =
lib.concatMapStrings (l: l + "\n") (lib.mapAttrsToList formatGtk2Option gtkIni)
+ cfg2.extraConfig
+ "\n";
inherit (cfg2) force;
};
home.sessionVariables.GTK2_RC_FILES = cfg2.configLocation;