Files
dotfiles/.config/git/config
Julian Prein 3d3ba75abb git: Use commit.template for a 2nd newline
When I write commit messages in vim, I often use gwap to format the
message body. This breaks if there is no empty line between the body and
the following "Please enter the commit message for your changes..."
comment.

So, to not always have to add this empty line first, I use a
commit.template file that simply contains one empty line.
2025-05-28 14:05:39 +02:00

127 lines
3.0 KiB
Plaintext

# vim: set ft=gitconfig fdm=indent fdi= fml=0 fdl=0:
[advice]
addIgnoredFile = off
detachedHead = off
[alias]
# NOTE: git-zsh-autoload (./zsh-autoload.sh) is a small wrapper that
# launches autoloadable zsh functions (.config/zsh/autoload/git/*) in
# the right directory, as shell commands in git aliases are executed
# from the top-level directory of the repository.
autosquash = -c sequence.editor=/bin/true rebase -i --autosquash
autofixup= autosquash
c = commit
changes = flog HEAD...FETCH_HEAD
checkout-worktree = "!git-zsh-autoload checkout-worktree"
cow = checkout-worktree
co = checkout
commit-last-msg = "!git-zsh-autoload commit-last-msg"
clm = commit-last-msg
last-msg = commit-last-msg
recommit = commit-last-msg --no-edit
f = fetch
fetch-tags-only = fetch origin "refs/tags/*:refs/tags/*"
ft = fetch-tags-only
filter-repo = !git-filter-repo
fixes = log -1 --pretty=fixes
glog = "!git-zsh-autoload glog"
https-and-ssh = "!git-zsh-autoload https-and-ssh"
ssh-and-https = https-and-ssh
l = log
last-changed = "!git-zsh-autoload last-changed"
ls = ls-files
make-fork = "!git-zsh-autoload make-fork"
p = push
perm-stash = "!git-zsh-autoload perm-stash"
root = rev-parse --show-toplevel
signoff = rebase --signoff
ss = stash
ssync = "!git-zsh-autoload ssync"
submodule-rm = "!git-zsh-autoload submodule-rm"
track = "!git-zsh-autoload track"
branches = track
[blame]
date = short
[branch]
autosetuprebase = always
sort = -committerdate
[color "status"]
added = 076
untracked = 014
[column]
ui = auto,column,dense
[commit]
gpgsign = true
# Add an additional newline, so that I can format the body more easily
# TODO: is there a way to use XDG_CONFIG_HOME?
template = ~/.config/git/message.template
verbose = true
[core]
abbrev = 12
#pager = delta
pager = diff-so-fancy \
| less --tabs=8 --RAW-CONTROL-CHARS --quit-if-one-screen
whitespace = trailing-spaces,space-before-tab,indent-with-non-tab
[delta]
navigate = true
commit-decoration-style = bold yellow box
file-style = bold yellow ul
file-decoration-style = none
hunk-header-decoration-style =
[diff]
# Color moved lines differently
colorMoved = default
colorMovedWS = ignore-all-space
# No rename limit, propagates to merge. and status.renameLimit too
renameLimit = 0
submodule = log
tool = nvimdiff
[difftool "meld"]
path = /usr/bin/meld
[fetch]
output = compact
prune = true
pruneTags = false
parallel = 0
[gpg]
program = gpg.loopback
[init]
defaultBranch = main
[interactive]
#diffFilter = delta --color-only
# Might need a `sudo cpan Term::ReadKey`
singleKey = true
[log]
follow = true
[merge]
conflictstyle = diff3
log = true
suppressDest = *
[pretty]
fixes = Fixes: %h (\"%s\")
[pull]
ff = yes
rebase = true
[push]
default = current
[rebase]
autostash = true
[rerere]
enabled = true
[status]
submodulesummary = true
[submodule]
fetchJobs = 0
[trailer]
where = end
[user]
email = julian@druck.dev
name = Julian Prein
signingkey = C0A44F69F2E29F6586C86B96CA6B3A516FAC2555
[include]
path = user.config