d58c650d59
- flake.nix: NixOS + home-manager + nixos-wsl 三输入 - hosts/wsl + hosts/bare: WSL 与裸机共享模块,分主机配置 - modules/: base(CLI 工具) + dev(工具链+LSP) + docker + locale + shell - home/: zsh(oh-my-zsh+插件+别名) + git(delta) + starship + 工具集成 - scripts/install.sh: 一键安装脚本(WSL/裸机通用) - 原 bun/go 全局包 hack 改为 nixpkgs 声明式管理
37 lines
769 B
Nix
37 lines
769 B
Nix
{ config, ... }:
|
|
|
|
{
|
|
programs.git = {
|
|
enable = true;
|
|
|
|
# user.name 和 user.email 需要每人自行设置:
|
|
# git config --global user.name "你的名字"
|
|
# git config --global user.email "你的邮箱"
|
|
|
|
delta = {
|
|
enable = true;
|
|
options = {
|
|
navigate = true;
|
|
side-by-side = true;
|
|
line-numbers = true;
|
|
};
|
|
};
|
|
|
|
extraConfig = {
|
|
# 内部 Git 服务器(跳过 SSL 验证)
|
|
http = {
|
|
"https://202.127.0.42:32443" = {
|
|
sslVerify = false;
|
|
};
|
|
};
|
|
|
|
credential.helper = "store";
|
|
merge.conflictstyle = "zdiff3";
|
|
pull.rebase = true;
|
|
push.autoSetupRemote = true;
|
|
init.defaultBranch = "main";
|
|
rerere.enabled = true;
|
|
};
|
|
};
|
|
}
|