rofi-pass: add package option

This commit is contained in:
Robert Walter 2023-09-19 20:24:36 +00:00 committed by GitHub
parent 8aac47a140
commit 7ee73f5363
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,11 +7,14 @@ let
cfg = config.programs.rofi.pass;
in {
meta.maintainers = [ maintainers.seylerius ];
meta.maintainers = with maintainers; [ seylerius robwalt ];
options.programs.rofi.pass = {
enable = mkEnableOption "rofi integration with password-store";
package =
mkPackageOption pkgs "rofi-pass" { example = "pkgs.rofi-pass-wayland"; };
stores = mkOption {
type = types.listOf types.str;
default = [ ];
@ -37,7 +40,7 @@ in {
};
config = mkIf cfg.enable {
home.packages = [ pkgs.rofi-pass ];
home.packages = [ cfg.package ];
xdg.configFile."rofi-pass/config".text = optionalString (cfg.stores != [ ])
("root=" + (concatStringsSep ":" cfg.stores) + "\n") + cfg.extraConfig