From 87a974a92cb3fc1abc64ca78a14bdee7f45565f6 Mon Sep 17 00:00:00 2001 From: Sergei Bulavintsev Date: Wed, 21 Feb 2024 15:25:11 +0300 Subject: [PATCH] feat(nix): move rbw to hm --- nix/homes/x86_64-linux/sab@nz/default.nix | 1 + .../{nixos/system => home}/security/rbw/default.nix | 8 ++++---- nix/modules/nixos/suites/desktop/default.nix | 1 - 3 files changed, 5 insertions(+), 5 deletions(-) rename nix/modules/{nixos/system => home}/security/rbw/default.nix (77%) diff --git a/nix/homes/x86_64-linux/sab@nz/default.nix b/nix/homes/x86_64-linux/sab@nz/default.nix index 26288a0..706c7ef 100644 --- a/nix/homes/x86_64-linux/sab@nz/default.nix +++ b/nix/homes/x86_64-linux/sab@nz/default.nix @@ -39,5 +39,6 @@ with lib.custom; { git = enabled; direnv = disabled; }; + security.rbw.enable = true; }; } diff --git a/nix/modules/nixos/system/security/rbw/default.nix b/nix/modules/home/security/rbw/default.nix similarity index 77% rename from nix/modules/nixos/system/security/rbw/default.nix rename to nix/modules/home/security/rbw/default.nix index e7dd37e..385656e 100644 --- a/nix/modules/nixos/system/security/rbw/default.nix +++ b/nix/modules/home/security/rbw/default.nix @@ -8,20 +8,20 @@ }: with lib; with lib.custom; let - cfg = config.system.security.rbw; + cfg = config.custom.security.rbw; in { - options.system.security.rbw = with types; { + options.custom.security.rbw = with types; { enable = mkBoolOpt false "Whether or not to enable rbw."; lockTimeout = mkOpt int 28800 "The amount of time to wait before continuing with shell init."; }; config = mkIf cfg.enable { - environment.systemPackages = with pkgs; [ + home.packages = with pkgs; [ rbw pinentry-gnome ]; - home.programs = { + programs = { rbw = { enable = true; settings = { diff --git a/nix/modules/nixos/suites/desktop/default.nix b/nix/modules/nixos/suites/desktop/default.nix index cdbff7f..3ad70b3 100644 --- a/nix/modules/nixos/suites/desktop/default.nix +++ b/nix/modules/nixos/suites/desktop/default.nix @@ -14,7 +14,6 @@ in { }; config = mkIf cfg.enable { - system.security.rbw.enable = true; custom = { desktop.addons = { keyring = enabled;