mirror of
https://github.com/JulienMalka/snowfield.git
synced 2025-03-28 23:00:58 +01:00
30 lines
653 B
Nix
30 lines
653 B
Nix
{ config, pkgs, lib, ... }:
|
|
let
|
|
cfg = config.luj.programs.git;
|
|
in
|
|
with lib;
|
|
{
|
|
options.luj.programs.git = {
|
|
enable = mkEnableOption "Enable git program";
|
|
};
|
|
|
|
config = mkIf cfg.enable {
|
|
programs.git = {
|
|
enable = true;
|
|
userName = "Julien Malka";
|
|
userEmail = "julien.malka@me.com";
|
|
signing = {
|
|
signByDefault = true;
|
|
key = "3C68E13964FEA07F";
|
|
};
|
|
};
|
|
|
|
home.extraActivationPath = [ pkgs.gnupg ];
|
|
home.activation =
|
|
{
|
|
myActivationAction = lib.hm.dag.entryAfter ["writeBoundary"] ''
|
|
gpg --import /run/secrets/git-gpg-private-key
|
|
'';
|
|
};
|
|
};
|
|
}
|