git 配置

vi ~/.gitconfig

安装开源命令行对比工具 delta: https://github.com/dandavison/delta

详细设置delta:https://www.5axxw.com/wiki/content/xrx4vf

bash 复制代码
[user]
	name = xx
	email = xx@xxxx.com

[core]
	attributesfile = ~/.gitattributes
	pager = delta
	quotepath = false
	
[credential]
	helper = cache --timeout=3600

[color]
	diff = auto
	status = auto
	branch = auto
	interactive = auto
	ui = true
	pager = true

[interactive]
	diffFilter = delta --color-only

[pull]
	rebase = true
	
[diff]
	colorMoved = default
	
[diff "image"]
	command = compare $2 $1 png:- | montage -geometry +4+4 $2 - $1 png:- | display -title \"$1\" -

[merge]
	conflictstyle = diff3
	ff = no
	commit = no

[delta]
	side-by-side = true
	line-numbers-left-format = ""
	line-numbers-right-format = "│ "
	syntax-theme = Nord
	navigate = true
	light = false

[clone]
	#recurseSubmodules = true

[alias]
	st = status
	br = branch
	lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
	last = log -1
相关推荐
小钟不想敲代码7 小时前
GitFlow
git·gitflow
云和数据.ChenGuang13 小时前
git commit复合指令
大数据·git·elasticsearch
-拟墨画扇-16 小时前
Git | 文件提交操作
git·gitee·github·gitcode
CoderJia程序员甲16 小时前
GitHub 热榜项目 - 日榜(2025-12-25)
git·ai·开源·llm·github
-拟墨画扇-18 小时前
Git | 文件修改操作
大数据·git·gitee·github·gitcode
-拟墨画扇-18 小时前
Git | 版本控制操作
大数据·git·gitee·github
GA66666619 小时前
PowerWiki:基于 Git 的知识管理系统
git
-拟墨画扇-20 小时前
Git | 状态查看操作
git·gitee·github·gitcode
码灵20 小时前
Git相关软件常用操作
git
-拟墨画扇-21 小时前
Git | 简介与安装
大数据·git·elasticsearch