-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgitconfig
executable file
·119 lines (119 loc) · 3.89 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
[alias]
st = status -sb
ci = commit
co = checkout
br = branch
rb = rebase
rbc = rebase --continue
rba = rebase --abort
rbs = rebase --skip
cp = cherry-pick
cpc = cherry-pick --continue
cpa = cherry-pick --abort
cpq = cherry-pick --quit
unstage = reset @
us = unstage
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
lga = log --graph --all --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
mt = mergetool
a = add -p
ignore = "!gi() { curl -L -s https://www.gitignore.io/api/$@ ;}; gi"
df = diff --word-diff
pmerge = merge -X patience --
mmerge = merge -X diff-algorithm=minimal
pf = push --force-with-lease
boom = "!git unstage; git checkout -- .; git clean -df"
cia = commit -a --amend --no-edit
rs = restore
sw = switch
oops = "!git commit -a --amend --no-edit; git push --force-with-lease"
patch = !git --no-pager diff --no-color
sm = submodule
smu = submodule update
smfe = submodule foreach
commitcount = !git rev-list HEAD | wc -l
cc = commitcount
# merged branch operations
mbu = !git branch --merged | grep -v \"[\\*\\+]\" | grep -E -v \"^\\s*(master|main|develop)\\$\"
mb = !git mbu | grep -v "hotfix[/-].*" | grep -v "release[/-].*"
dmb = !git mb | xargs -n 1 git branch -d
dmbu = !git mbu | xargs -n 1 git branch -d
# remote merged branch operations
mbru = !git branch -r --merged | grep origin | sed 's/ origin\\///' | grep -v \"[\\*\\+]\" | grep -E -v \"^\\s*(master|main|develop)$\" | grep -v "HEAD"
mbr = !git mbru | grep -v "^\\s*hotfix[/-]" | grep -v "^\\s*release[/-]"
dmbr = !git mbr | xargs -n 1 git push -d origin
dmbru = !git mbru | xargs -n 1 git push -d origin
# unmerged branch operations
umbu = !git branch --no-merged | grep -v \"[\\*\\+]\" | grep -E -v \"^\\s*(master|main|develop)\\$\"
umb = !git umbu | grep -v "hotfix[/-].*" | grep -v "release[/-].*"
dumb = !git umb | xargs -n 1 git branch -D
dumbu = !git umbu | xargs -n 1 git branch -D
# remote unmerged branch operations
umbru = !git branch -r --no-merged | grep origin | sed 's/ origin\\///' | grep -v \"[\\*\\+]\" | grep -E -v \"^\\s*(master|main|develop)$\"
umbr = !git umbru | grep -v "^\\s*hotfix[-/]" | grep -v "^\\s*release[/-]"
dumbr = !git umbr | xargs -n 1 git push -d origin
dumbru = !git umbru | xargs -n 1 git push -d origin
[user]
name = Kevin Lundberg
email = [email protected]
[color]
ui = true
[branch]
autosetuprebase = always
[core]
excludesfile = /Users/klundberg/.dotfiles/gitignore_global
fsmonitor = true
[pager]
diff = diff-so-fancy | less --tabs=1,5 -RFX
show = diff-so-fancy | less --tabs=1,5 -RFX
[difftool "p4merge"]
cmd = /Applications/p4merge.app/Contents/MacOS/p4merge \"$LOCAL\" \"$REMOTE\"
[merge]
keepBackup = false;
tool = p4merge
[mergetool]
keepBackup = false
keepTemporaries = false
trustExitCode = true
[mergetool "p4merge"]
cmd = /Applications/p4merge.app/Contents/MacOS/p4merge \"$BASE\" \"$LOCAL\" \"$REMOTE\" \"$MERGED\"
trustExitCode = false
[mergetool "kaleidoscope"]
trustExitCode = true
cmd = /usr/local/bin/ksdiff --merge --output \"$MERGED\" --base \"$BASE\" -- \"$LOCAL\" --snapshot \"$REMOTE\"
[diff "localizablestrings"]
textconv = "iconv -f utf-16 -t utf-8"
[push]
default = simple
autoSetupRemote = true
[pull]
rebase = true
[credential]
helper = osxkeychain
[rerere]
enabled = true
[fetch]
prune = true
[commit]
template = /Users/klundberg/.stCommitMsg
[rebase]
autoStash = true
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[pack]
useSparse = true
[interactive]
diffFilter = diff-so-fancy --patch
[init]
defaultBranch = main
[advice]
detachedHead = false
[mergetool "vscode"]
cmd = code --wait --merge $REMOTE $LOCAL $BASE $MERGED
[diff]
tool = vscode
[difftool "vscode"]
cmd = code --wait --diff $LOCAL $REMOTE