dotfiles/git/.config/git/config
Marty Oehme e418e2508f
git: Add sendmail configuration
Added configuration to use git for direct patch contributions through
mail. Uses msmtp for mail agent.
2022-11-25 16:44:43 +01:00

61 lines
2.4 KiB
Text

[user]
email = marty.oehme@gmail.com
name = Marty Oehme
signingkey = 73BA40D5AFAF49C9
[init]
defaultBranch = main
[sendemail]
smtpserver = "/usr/bin/msmtp"
annotate = yes
[alias]
ignore = "!gitignore -f"
pushmerge = "push -o merge_request.merge_when_pipeline_succeeds" # see https://docs.gitlab.com/ce/user/project/push_options.html # merge-when-pipeline-succeeds-alias
last = "diff HEAD~ HEAD"
pushall = "!git remote | xargs -I R git push R" # push to all connected remotes
fetchall = "!git remote | xargs -I R git fetch R" # fetch from all connected remotes
[commit]
gpgsign = true # sign commits as me
verbose = true # Always show diff when preparing commit message
[fetch]
prune = true # remove references to non-existent remote branches
[pull]
rebase = true # always rebase on pulling, obviates merge commits
[diff]
colorMoved = zebra # also color stuff that has simply been moved, in a classy zebra-color
[pager]
diff = dsf | less --tabs=4 -RFXS --pattern '(^(Date|added|deleted|modified): |^diff --git )'
[color.diff]
meta = "9"
frag = "magenta bold"
commit = "yellow bold"
old = "red bold"
new = "green bold"
whitespace = "red reverse"
[color.diff-highlight]
oldNormal = "red bold"
oldHighlight = "red bold 52"
newNormal = "green bold"
newHighlight = "green bold 22"
[rebase]
autostash = true
autoSquash = true
# Make use of git urls for git{lab,hub}, but only do so for pushing
# since pulling will create troubles with some applications
[url "git@github.com:"]
pushInsteadOf = "https://github.com/"
pushInsteadOf = "http://github.com/"
pushInsteadOf = "gh:"
[url "git@gitlab.com:"]
pushInsteadOf = "https://gitlab.com"
pushInsteadOf = "http://gitlab.com"
[url "git@git.martyoeh.me:"]
pushInsteadOf = "https://git.martyoeh.me"
pushInsteadOf = "http://git.martyoeh.me"
pushInsteadOf = "git@martyoeh.me"
pullInsteadOf = "git@martyoeh.me"
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true