major refactor

This commit is contained in:
Henri Dohmen 2025-12-23 23:05:32 +01:00
parent 20472f8d1b
commit d778875a1b
Signed by: hd
GPG key ID: AB79213B044674AE
32 changed files with 495 additions and 428 deletions

38
mod/desktop/gpg.nix Normal file
View file

@ -0,0 +1,38 @@
{
config,
lib,
pkgs,
...
}:
let
cfg = config.hd.desktop.gpg;
inherit (lib) mkEnableOption mkIf;
in
{
config = mkIf cfg.enable {
home = {
home.packages = with pkgs; [
libsecret
gnome-keyring
];
programs.gpg = {
enable = true;
publicKeys = [
{
source = ../../pgp/id-priv.pgp;
trust = 5;
}
{
source = ../../pgp/id-uni.pgp;
trust = 5;
}
];
};
services.gpg-agent = {
enable = true;
enableSshSupport = true;
pinentry.package = pkgs.pinentry-gtk2;
};
};
};
}