forked from amix/vimrc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gitconfig
73 lines (73 loc) · 2 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
[core]
[merge]
tool = diffuse
[diff]
tool = meld
[color]
ui = true
status = auto
branch = auto
diff = true
[user]
useconfigonly = true
[alias]
lol = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
lola = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all
st = status
df = diff
co = checkout
ci = commit -s
br = branch
rb = rebase
rbc = rebase --continue
rbi = rebase -i
amend = commit --amend
cleanws = rebase --whitespace=fix
ls = show --pretty=oneline --abbrev-commit --name-status
lls = log --pretty=oneline --abbrev-commit --name-status
showtool = "!sh -c 'if [ -z $1 ]; then REVISION=HEAD; else REVISION=$1; fi; git difftool $REVISION~ $REVISION' -"
gblame = gui blame
hard = reset --hard
spr = "!f() { git fetch -fu ${2:-$(git remote |grep ^stash- || echo origin)} refs/pull-requests/$1/from:pr/$1 && git checkout pr/$1; }; f"
pr-clean = "!git for-each-ref refs/heads/pr/* --format=\"%(refname)\" | while read ref ; do branch=${ref#refs/heads/} ; git branch -D $branch ; done"
fetcha = fetch --all --prune
[color "diff"]
whitespace = red reverse
meta = yellow bold
frag = magenta bold
old = red
new = green bold
[color "status"]
added = yellow
changed = green
untracked = cyan
[core]
autocrlf = input
whitespace = trailing-space,space-before-tab,fix,-indent-with-non-tab,cr-at-eol
editor = vim
safecrlf = false
pager = sed 's/\t/. /g' | less -R -F -X
[gitreview]
remote = origin
[filter "trimWhitespace"]
clean = git-stripspace
[rebase]
autostash = true
abbreviateCommands = true
instructionFormat = -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset
[push]
default = simple
[pager]
log = diff-highlight | less
show = diff-highlight | less
diff = diff-highlight | less
[interactive]
diffFilter = diff-highlight
[help]
autocorrect = 10
[pull]
rebase = true
[rerere]
enabled = true
[fetch]
prune = true