mirror of
https://github.com/nix-community/home-manager
synced 2024-12-22 01:39:47 +01:00
feh: Add package option (#3552)
Co-authored-by: Naïm Favier <n@monade.li> Co-authored-by: Sumner Evans <me@sumnerevans.com>
This commit is contained in:
parent
dd99675ee8
commit
c1a830c8fa
1 changed files with 3 additions and 1 deletions
|
@ -27,6 +27,8 @@ in {
|
|||
options.programs.feh = {
|
||||
enable = mkEnableOption "feh - a fast and light image viewer";
|
||||
|
||||
package = mkPackageOption pkgs "feh" { };
|
||||
|
||||
buttons = mkOption {
|
||||
default = { };
|
||||
type = with types; bindingsOf (either str int);
|
||||
|
@ -69,7 +71,7 @@ in {
|
|||
"To disable a keybinding, use `null` instead of an empty string.";
|
||||
}];
|
||||
|
||||
home.packages = [ pkgs.feh ];
|
||||
home.packages = [ cfg.package ];
|
||||
|
||||
xdg.configFile."feh/buttons" =
|
||||
mkIf (cfg.buttons != { }) { text = renderBindings cfg.buttons + "\n"; };
|
||||
|
|
Loading…
Reference in a new issue