Files
nixconfig/modules/nixos/gnupg.nix
T
aaronandClaude Opus 5.5 1abb1ca6a1 chore: drop redundant packages and options
- packages.nix is the baseline: drop neovim (nixvim), nvd, sof-firmware (enableAllFirmware), qtmultimedia (v4 leftover); vial moves to vial.nix, wl-clipboard to noctalia.nix, claude-code becomes a plain package here
- drop packages and options already provided elsewhere: noctalia (home-manager), gnupg/pinentry-qt (agent), gtk/qt themes, sddm Theme.Current, zsh plugins (home-manager), group = users, empty firewall lists
- single-package lists without `with pkgs;`, steam package inside its block

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-02 09:25:40 +02:00

27 lines
820 B
Nix

# A graphical pinentry never grabs the tty, so a passphrase prompt can't take
# over a terminal driven by a coding agent. The cache lasts a working day, and
# an unattended signature fails after two minutes instead of blocking forever.
{ config, pkgs, ... }:
{
programs.gnupg.agent = {
enable = true;
pinentryPackage = pkgs.pinentry-qt;
settings = {
default-cache-ttl = 86400;
max-cache-ttl = 86400;
pinentry-timeout = 120;
};
};
environment.systemPackages = [
pkgs.pinentry-curses # fallback for sessions without a display
# prime the passphrase cache on demand, e.g. before an agent session
(pkgs.writeShellScriptBin "gpg-unlock" ''
echo | ${config.programs.gnupg.package}/bin/gpg --clearsign --output /dev/null
echo "gpg key unlocked"
'')
];
}