-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgitconfig
132 lines (119 loc) · 3.27 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
[user]
name = Steve McKinney
email = [email protected]
[includeIf "gitdir:~/code/work/"]
path = ~/.gitconfig-work
[github]
user = stephenmckinney
[alias]
# blame
blame = blame -w
# branch
b = branch
ba = branch -av
bd = branch -d
bm = branch -m
bs = show-branch
# checkout/fetch/merge/push/rebase
# checkout
co = checkout
cob = checkout -b
co0 = checkout HEAD --
com = checkout main
# fetch
f = fetch
fm = pull
fo = fetch origin
fu = fetch upstream
# merge
m = merge
mom = merge origin/main
# push
p = push
pa = push --all
pt = push --tags
# rebase
r = rebase
ra = rebase --abort
rc = rebase --continue
ri = rebase --interactive
rs = rebase --skip
rom = rebase origin/main
riom = rebase --interactive origin/main
# commit
c = commit --verbose
cm = commit --verbose --message
ca = commit --verbose --all
cam = commit --verbose --all --message
camend = commit --amend --reuse-message HEAD
camendm= commit --amend --verbose
cp = cherry-pick -sex
# verbose alternatives
undo-last-commit = reset --soft "HEAD^"
#stash
sl = stash list
ss = stash show
ssp = stash show -p
sp = stash pop
sd = stash drop
sc = stash clear
# diff
d = diff # Diff working dir to index
dw = diff -w # Diff ignore whitespace
ds = diff --staged # Diff index to HEAD
dc = diff --staged # Diff index to HEAD
dh = diff HEAD # Diff working dir and index to HEAD
# hub
h = browse
hc = compare
# index
s = status
a = add
ia = add
ir = reset
unstage = reset HEAD
# log
l = log --topo-order --pretty=format:'%C(yellow)%h %C(cyan)%cn %C(blue)%cr%C(reset) %s'
ls = log --topo-order --stat --pretty=format:'%C(bold)%C(yellow)Commit:%C(reset) %C(yellow)%H%C(red)%d%n%C(bold)%C(yellow)Author:%C(reset) %C(cyan)%an <%ae>%n%C(bold)%C(yellow)Date:%C(reset) %C(blue)%ai (%ar)%C(reset)%n%+B'
ld = log --topo-order --stat --patch --full-diff --pretty=format:'%C(bold)%C(yellow)Commit:%C(reset) %C(yellow)%H%C(red)%d%n%C(bold)%C(yellow)Author:%C(reset) %C(cyan)%an <%ae>%n%C(bold)%C(yellow)Date:%C(reset) %C(blue)%ai (%ar)%C(reset)%n%+B'
lg = log --topo-order --all --graph --pretty=format:'%C(yellow)%h%C(reset) %s %C(red)%d%C(reset)%n'
lga = log --topo-order --all --graph --pretty=format:'%C(yellow)%h %C(cyan)%cn%C(reset) %s %C(red)%d%C(reset)%n'
lm = log --topo-order --pretty=format:'%s'
lh = shortlog --summary --numbered
llf = fsck --lost-found
lme = log --author='Steve McKinney'
# show
sh = show HEAD
# remote
re = remote
rel = remote --verbose
rea = remote add
rex = remote rm
rem = remote rename
rep = remote prune origin
[blame]
date = format:%Y-%m-%d
[color]
ui = auto
[commit]
verbose = true
[core]
excludesfile = $HOME/.gitignore
editor = nvim -f
quotepath = false
[mergetool "fugitive"]
cmd = nvim -f -c \"Gdiff\" \"$MERGED\"
[merge]
tool = fugitive
# 'simple' - in centralized workflow (e.g. Github), work like 'upstream' with an added
# safety to refuse to push if the upstream branch’s name is different from the local one.
[push]
default = simple
[apply]
whitespace = nowarn
[heroku]
account = personal
[credential]
helper = osxkeychain
[init]
defaultBranch = main