mirror of
https://github.com/itme-brain/nixos.git
synced 2026-03-24 08:39:42 -04:00
27 lines
518 B
Nix
27 lines
518 B
Nix
{ lib, config, ... }:
|
|
|
|
with lib;
|
|
let
|
|
cfg = config.modules.gpg;
|
|
isBryan = config.user.name == "bryan";
|
|
|
|
in
|
|
{ options.modules.gpg = { enable = mkEnableOption "gpg"; };
|
|
config = mkIf cfg.enable {
|
|
programs.gpg = {
|
|
enable = true;
|
|
publicKeys = if isBryan then [
|
|
{
|
|
text = import ./config/pubKey.nix;
|
|
trust = 5;
|
|
}
|
|
] else [];
|
|
};
|
|
|
|
services.gpg-agent = {
|
|
enable = true;
|
|
enableSshSupport = true;
|
|
enableBashIntegration = true;
|
|
};
|
|
};
|
|
}
|