diff --git a/flake.nix b/flake.nix index 4543659..f14fc8a 100644 --- a/flake.nix +++ b/flake.nix @@ -64,6 +64,7 @@ # Add private homelab and cloud host aliases homeManagerModules.private = { ... }: { imports = [ + ./home/private/git.nix ./home/private/ssh-hosts.nix ]; }; diff --git a/home/private/git.nix b/home/private/git.nix new file mode 100644 index 0000000..9c807b9 --- /dev/null +++ b/home/private/git.nix @@ -0,0 +1,24 @@ +{ ... }: +{ + programs.git = { + enable = true; + + extraConfig = { + credential.helper = "store --file ~/.git-credentials"; + + "url \"https://g.t1.xyz/github-mirror/\"" = { + insteadOf = [ + "https://github.com/AirGuanZ/" + "https://github.com/dmlc/" + "https://github.com/epezent/" + "https://github.com/facebook/" + "https://github.com/lz4/" + "https://github.com/nothings/" + "https://github.com/ocornut/" + "https://github.com/rapidsai/" + "https://github.com/yhirose/" + ]; + }; + }; + }; +}