move all home level programs to progems dir
This commit is contained in:
parent
77d70dcf2e
commit
bc450a9fe7
27 changed files with 27 additions and 21 deletions
47
home/modules/programs/gpg/default.nix
Normal file
47
home/modules/programs/gpg/default.nix
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
outputs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
options = {
|
||||
youthlic.programs.gpg = {
|
||||
enable = lib.mkEnableOption "gpg";
|
||||
};
|
||||
};
|
||||
config =
|
||||
let
|
||||
cfg = config.youthlic.programs.gpg;
|
||||
in
|
||||
lib.mkIf cfg.enable {
|
||||
services.gpg-agent = lib.mkMerge [
|
||||
{
|
||||
enable = true;
|
||||
enableSshSupport = true;
|
||||
pinentryPackage = outputs.packages."${pkgs.system}".pinentry-selector;
|
||||
sshKeys = [
|
||||
"C817E333BF88F16EA0F7ADE27BDCCC16AD25E5A6"
|
||||
];
|
||||
}
|
||||
(lib.mkIf config.youthlic.programs.fish.enable {
|
||||
enableFishIntegration = true;
|
||||
})
|
||||
(lib.mkIf config.youthlic.programs.bash.enable {
|
||||
enableBashIntegration = true;
|
||||
})
|
||||
];
|
||||
programs.gpg = {
|
||||
enable = true;
|
||||
mutableKeys = true;
|
||||
mutableTrust = true;
|
||||
publicKeys = [
|
||||
{
|
||||
source = ./public-key.txt;
|
||||
trust = "ultimate";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue