-
Notifications
You must be signed in to change notification settings - Fork 5
/
.gitconfig
156 lines (128 loc) · 3.94 KB
/
.gitconfig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
[user]
name = Sean Williams
email = [email protected]
signingkey = D911E4AB259CE385
[core]
editor = nvim
excludesfile = ~/.gitignore
quotePath = false
commitGraph = true
[color]
ui = auto
[alias]
aa = add --all
add-branch = "!f() { BRANCH=$1; if [[ -z ${BRANCH} ]]; then echo >&2 "Specify branch name!"; exit 1; fi; git checkout -b ${BRANCH}; git push -u; }; f "
add-tag = !sh -c \"git tag "$1" && git push origin --tags\"
amp = !sh -c \"git add . && git can && git push -f\"
b = branch
blg = branch --format '%(color:red)%(objectname:short)%(color:reset) %(color:green)%(committerdate:iso)%(color:reset) %(subject) %(color:bold blue)-- %(authorname)%(color:reset) %(color:yellow)(%(refname:short))%(color:reset)'
ca = commit --amend
can = commit --amend --no-edit -n
cap = !sh -c \"git can && git push -f\"
change-commits = "!f() { VAR=$1; OLD=$2; NEW=$3; shift 3; git filter-branch -f --env-filter \"if [ \\\"$`echo $VAR`\\\" = '$OLD' ]; then export $VAR='$NEW'; fi\" $@; }; f "
ci = commit
co = checkout
commitnow = "!git commit --amend --date \"`date +%s`\" #"
cp = cherry-pick
cpc = cherry-pick --continue
dc = diff --cached
dh1 = diff HEAD~1
di = diff
ds = diff --staged
fa = fetch --all
ff = merge --ff-only
glg = log --graph --abbrev-commit --decorate --all --pretty=glg
glgs = log --graph --abbrev-commit --decorate --pretty=glg
h = head
head = log -1
ld = log --no-merges --pretty=fuller
lg = log --pretty=lg
ls = log --author='Sean Williams' --no-merges --stat --pretty=medium
lsp = ls -p
wtls = worktree list
wtrm = worktree list
mt = mergetool
new = !sh -c 'git log $1@{1}..$1@{0} "$@"'
noff = merge --no-ff
pa = pull --all
pom = push origin master
pp = !sh -c \"git pull --all && git pushall\"
prune-all = !git remote | xargs -n 1 git remote prune
pua = pushall
pullff = pull --ff-only
pushall = !git remote | xargs -n 1 git push
rc = rebase --continue
set-remote = !git-set-remote "$1"
show-ignored-files = ls-files . --ignored --exclude-standard --others
show-untracked-files = ls-files . --exclude-standard --others
showd = show --pretty=fuller
slg = stash list --pretty=reflg
sr = set-remote
st = status
undo = reset --hard
up = !sh -c \"git commit -a -m \"Before rebase\" && git pull --rebase && git reset head^\"
wt = "!f() { case \"$1\" in add) shift; git add-worktree \"$@\" ;; ls) shift; git worktree list \"$@\" ;; rm) shift; git worktree remove \"$@\" ;; *) git worktree \"$@\" ;; esac; }; f"
wu = log --stat origin..@{0}
wup = log -p origin..@{0}
[diff]
tool = nvimdiff
colorMoved = default
[diff "sopsdiffer"]
textconv = "sops -d"
[difftool]
prompt = false
[difftool "nvimdiff"]
cmd = "nvim -d -u ~/.vimrc \"$LOCAL\" \"$REMOTE\""
[merge]
tool = nvimdiff
conflictStyle = diff3
[mergetool]
prompt = false
keepBackup = false
[mergetool "nvimdiff"]
cmd = "nvim -d -u ~/.vimrc \"$LOCAL\" \"$MERGED\" \"$REMOTE\""
[delta]
navigate = true # use n and N to move between diff sections
hyperlinks = true
[pretty]
lg = %C(red)%h%C(reset) - %C(green)%ci%C(reset) %s %C(bold blue)-- %an%C(reset)%C(yellow)%d%C(reset)
glg = %C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an <%ae>%C(reset)%C(bold yellow)%d%C(reset)
worklog = [%as](%h): %s
reflg = %C(red)%h%C(reset) %C(green)%ci%C(reset) %s %C(bold blue)-- %an%C(reset) %C(yellow)(%gd)%C(reset)
[push]
default = current
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[http]
sslVerify = false
followRedirects = true
[credential]
helper = store
[pull]
rebase = true
[submodule]
recurse = true
[daemon]
receivepack = true
[receive]
advertisePushOptions = true
procReceiveRefs = refs/for
[gc]
writeCommitGraph = true
pruneExpire = now
aggressive = true
[init]
defaultBranch = main
[advice]
skippedCherryPicks = false
[checkout]
defaultRemote = origin
[column]
ui = auto
[branch]
sort = -committerdate
[worktree]
guessRemote = true