diff --git a/users/jeirmeister/programs/git.nix b/users/jeirmeister/programs/git.nix index f877057..f09cf93 100644 --- a/users/jeirmeister/programs/git.nix +++ b/users/jeirmeister/programs/git.nix @@ -1,18 +1,23 @@ -# users/jeirmeister/programs/git.nix { config, pkgs, ... }: { programs.git = { enable = true; - package = pkgs.git.override { withLibsecret = true; }; lfs.enable = true; userName = "jeirmeister"; userEmail = "jeir@jeirslab.xyz"; + extraConfig = { init.defaultBranch = "main"; pull.rebase = false; - credential.helper = "${pkgs.libsecret}/bin/git-credential-libsecret"; + + # Configure credential helper + credential = { + helper = "${pkgs.git-credential-manager}/bin/git-credential-manager"; + useHttpPath = true; + }; }; + ignores = [ ".DS_Store" "*.swp" @@ -20,4 +25,16 @@ ".idea/" ]; }; -} + + # Ensure required KDE packages are installed + home.packages = with pkgs; [ + git-credential-manager + ksshaskpass + ]; + + # Set environment variables for KDE integration + home.sessionVariables = { + GIT_ASKPASS = "${pkgs.ksshaskpass}/bin/ksshaskpass"; + SSH_ASKPASS = "${pkgs.ksshaskpass}/bin/ksshaskpass"; + }; +} \ No newline at end of file