-
Notifications
You must be signed in to change notification settings - Fork 0
/
gitconfig
71 lines (61 loc) · 1.96 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
[init]
defaultBranch = main
[user]
; email = [email protected]
email = [email protected]
name = Brenda Thng
signingkey = /Users/bthng/.ssh/id_rsa.pub
# signingkey = /Users/bthng/.ssh/id_rsa.pub
[includeIf "gitdir:~/github/messari/"]
path = ~/github/messari/.gitconfig
[core]
excludesfile = ~/.gitignore_global
pager = delta
[pull]
ff = only
[alias]
coauthor = "!f() { git commit --amend -m \"$(git log -1 --pretty=%B)\" -m \"Co-authored-by: $1\"; }; f"
mwps = "!f() { git push -o merge_request.create -o merge_request.target=master; }; f"
gcd = "git checkout develop"
diffs = "-c delta.side-by-side=true diff"
s = status -s
co = checkout
cob = checkout -b
# list branches sorted by last modified
b = "!git for-each-ref --sort='-authordate' --format='%(authordate)%09%(objectname:short)%09%(refname)' refs/heads | sed -e 's-refs/heads/--'"
# list aliases
la = "!git config -l | grep alias | cut -c 7-"
prev = checkout @{-1}
# rebase on main origin branch
rom = !git fetch --all && git rebase $(git rev-parse --abbrev-ref origin/HEAD)
# reset the branch to the distant one
rh = !git fetch && git reset --hard origin/$(git rev-parse --abbrev-ref HEAD)
# interactive rebasing
ri = "!f() { git rebase -i HEAD~$1; }; f"
# view merged branches - to be deleted
gone="! git branch -vv | grep ': gone]' "
cleanup="! git branch --merged | egrep -v master"
[pack]
windowMemory = 100m
SizeLimit = 100m
threads = 1
window = 0
[credential]
helper = cache
[credential "https://dev.azure.com"]
useHttpPath = true
[commit]
gpgsign = true
[gpg]
format = ssh
[interactive]
diffFilter = delta --color-only
[delta]
navigate = true # use n and N to move between diff sections
light = false # set to true if you're in a terminal w/ a light background color (e.g. the default macOS terminal)
hyperlinks = false # set to true to link to commits
side-by-side = true
[merge]
conflictstyle = diff3
[diff]
colorMoved = default