From beeed2baa2ae80dd357ef880819a71926a4dfa44 Mon Sep 17 00:00:00 2001 From: William Carroll Date: Fri, 13 Mar 2020 16:54:51 +0000 Subject: Prefer locally installed /usr/bin/git From what I understand, gLinux and Nix are sometimes compatible and sometimes incompatible. Some nix-installed programs rely on system state that differs from gLinux's system state. In other cases, Google wraps existing programs (e.g. git) to provide Google-specific configuration. Ever since I switched to home-manager and set `programs.git.enable = true`, magit, which uses the git that PATH exposes hasn't been able to push, fetch, and a few other commands. TODO(wpcarro): Define a base home.nix that my gLinux and NixOS machines can extend. --- configs/.config/nixpkgs/home.nix | 3 +++ 1 file changed, 3 insertions(+) (limited to 'configs') diff --git a/configs/.config/nixpkgs/home.nix b/configs/.config/nixpkgs/home.nix index 08dd489b9988..5d1f575eabe9 100644 --- a/configs/.config/nixpkgs/home.nix +++ b/configs/.config/nixpkgs/home.nix @@ -41,6 +41,9 @@ programs.git = { enable = true; + package = pkgs.writeShellScriptBin "git" '' + exec /usr/bin/git "$@" + ''; userName = "William Carroll"; userEmail = "wpcarro@gmail.com"; aliases = { -- cgit 1.4.1