From 9dfdce2df424be3f19ad7d357de5e07489a61e04 Mon Sep 17 00:00:00 2001 From: Christian Harke Date: Thu, 27 Jun 2024 22:32:19 +0200 Subject: [PATCH 1/3] Enable ssh-agent --- home/programs/ssh/default.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/home/programs/ssh/default.nix b/home/programs/ssh/default.nix index 6299fd33..5ddadc80 100644 --- a/home/programs/ssh/default.nix +++ b/home/programs/ssh/default.nix @@ -33,9 +33,12 @@ in homeage.file = listToAttrs (map mkHomeageFile cfg.identities); programs.ssh = { enable = true; + addKeysToAgent = "yes"; controlMaster = "auto"; controlPath = "~/.ssh/master-%r@%n:%p"; controlPersist = "10m"; }; + + services.ssh-agent.enable = true; }; } From c6a1a3042cb982c268b33a2c076b7c441c6d49a9 Mon Sep 17 00:00:00 2001 From: Christian Harke Date: Fri, 28 Jun 2024 23:19:30 +0200 Subject: [PATCH 2/3] Add git credentials helper to store https credentials --- home/roles/desktop/default.nix | 1 + home/users/christian/git/default.nix | 2 ++ 2 files changed, 3 insertions(+) diff --git a/home/roles/desktop/default.nix b/home/roles/desktop/default.nix index 61db849b..153f7587 100644 --- a/home/roles/desktop/default.nix +++ b/home/roles/desktop/default.nix @@ -110,6 +110,7 @@ in gnome.gnome-characters gnome.nautilus gnome.pomodoro + gnome.seahorse mupdf peek gifski diff --git a/home/users/christian/git/default.nix b/home/users/christian/git/default.nix index 0e871a40..77e14c99 100644 --- a/home/users/christian/git/default.nix +++ b/home/users/christian/git/default.nix @@ -24,6 +24,7 @@ in programs.git = { enable = true; + package = pkgs.gitFull; lfs.enable = true; userName = "Christian Harke"; signing.key = "630966F4"; @@ -47,6 +48,7 @@ in }; extraConfig = { + credential.helper = "${pkgs.gitFull}/share/git/contrib/credential/libsecret/git-credential-libsecret"; maintenance.repo = [ "${config.home.homeDirectory}/.nix-config" "${config.home.homeDirectory}/code/nixcfg" From 148685587f889134113ac64a528817215041433d Mon Sep 17 00:00:00 2001 From: Christian Harke Date: Fri, 28 Jun 2024 23:19:46 +0200 Subject: [PATCH 3/3] Refactor gpg pinentry config --- home/users/christian/gpg/default.nix | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/home/users/christian/gpg/default.nix b/home/users/christian/gpg/default.nix index 75bda4d5..300c0548 100644 --- a/home/users/christian/gpg/default.nix +++ b/home/users/christian/gpg/default.nix @@ -18,13 +18,8 @@ in }; config = mkIf cfg.enable { - - home.file.".gnupg/gpg-agent.conf" = { - text = '' - pinentry-program ${getExe pinentryPkg} - ''; - }; - programs.gpg.enable = true; + + services.gpg-agent.pinentryPackage = pinentryPkg; }; }