From 6ca422c900c1ae7c28457c262f066d161eab591c Mon Sep 17 00:00:00 2001 From: Miran Bastaja Date: Tue, 10 Sep 2024 23:47:25 +0200 Subject: hyprdesktop: enable senpai IRC client --- hosts/wonderland/home.nix | 8 +++++++- hosts/wonderland/sops.nix | 6 ++++-- share/cfg/default.nix | 1 + share/cfg/senpai.nix | 7 +++++-- share/hm-modules/hyprdesktop.nix | 1 + 5 files changed, 18 insertions(+), 5 deletions(-) diff --git a/hosts/wonderland/home.nix b/hosts/wonderland/home.nix index 1d8f3a7..a970261 100644 --- a/hosts/wonderland/home.nix +++ b/hosts/wonderland/home.nix @@ -1,4 +1,9 @@ -{ flakeRoot, inputs, ... }: +{ + flakeRoot, + inputs, + config, + ... +}: { home-manager = { useGlobalPkgs = true; @@ -6,6 +11,7 @@ sharedModules = [ { imports = [ (flakeRoot + /share/cfg) ]; } ]; extraSpecialArgs = { inherit inputs; + inherit (config) sops; }; }; diff --git a/hosts/wonderland/sops.nix b/hosts/wonderland/sops.nix index 8c2268f..9b76b24 100644 --- a/hosts/wonderland/sops.nix +++ b/hosts/wonderland/sops.nix @@ -1,4 +1,4 @@ -{ ... }: +{ config, ... }: { sops = { age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ]; @@ -15,7 +15,9 @@ # "spotify/username" = { # mode = "444"; # }; - "irc/libera-password" = { }; + "irc/libera-password" = { + owner = config.users.users.alice.name; + }; }; }; # end of sops } diff --git a/share/cfg/default.nix b/share/cfg/default.nix index 373e1a1..dfee598 100644 --- a/share/cfg/default.nix +++ b/share/cfg/default.nix @@ -16,5 +16,6 @@ ./shellenv.nix ./hyprland.nix ./jujutsu.nix + ./senpai.nix ]; } diff --git a/share/cfg/senpai.nix b/share/cfg/senpai.nix index 43d5083..4440a6d 100644 --- a/share/cfg/senpai.nix +++ b/share/cfg/senpai.nix @@ -1,8 +1,11 @@ -{ config, ... }: +{ sops, ... }: { programs.senpai.config = { address = "irc.libera.chat"; nickname = "miranb"; - password-cmd = "cat ${config.sops.secrets."irc/libera-password".path}"; + password-cmd = [ + "cat" + sops.secrets."irc/libera-password".path + ]; }; } diff --git a/share/hm-modules/hyprdesktop.nix b/share/hm-modules/hyprdesktop.nix index ce997f8..135a457 100644 --- a/share/hm-modules/hyprdesktop.nix +++ b/share/hm-modules/hyprdesktop.nix @@ -160,6 +160,7 @@ in programs.atuin.enable = true; programs.nix-index.enable = true; programs.zoxide.enable = true; + programs.senpai.enable = true; programs.direnv = { enable = true; -- cgit v1.3.1