forked from aziz/dotfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgitconfig
More file actions
70 lines (70 loc) · 1.96 KB
/
gitconfig
File metadata and controls
70 lines (70 loc) · 1.96 KB
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
[alias]
co = checkout
unstage = reset HEAD
undo = reset --soft HEAD^
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative
lol = log --pretty=oneline --abbrev-commit --graph --decorate
conflicts = !git ls-files --unmerged | cut -c51- | sort -u | xargs $EDITOR
resolve = !git ls-files --unmerged | cut -c51- | sort -u | xargs git add
unpushed = cherry -v
upstream = rev-parse --symbolic-full-name --abbrev-ref HEAD@{upstream}
amend = commit --amend
branch-cleanup = !sh -c 'git branch --merged | grep -v master | xargs git branch -d && git remote prune origin'
# Interactive rebase with the given number of latest commits
reb = "!r() { git rebase -i HEAD~$1; }; r"
# Remove branches that have already been merged with master
# a.k.a. ‘delete merged’
dm = "!git branch --merged | grep -v '\\*' | xargs -n 1 git branch -d"
[core]
excludesfile = ~/.gitignore
editor = subl -wn
autocrlf = input
whitespace = space-before-tab, trailing-space
[help]
autocorrect = 1
[merge]
log = true
[apply]
whitespace = fix
[push]
default = current
followTags = true
[branch]
autosetupmerge = true
autosetuprebase = always
mergeoptions = --no-ff
[status]
relativePaths = true
[format]
pretty = %C(yellow)%h%Creset %s %C(red)(%an, %cr)%Creset
[color]
diff = auto
status = auto
branch = auto
interactive = auto
ui = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "status"]
header = white dim
branch = yellow
added = green
changed = red
untracked = blue
[color "diff"]
meta = blue bold reverse
frag = magenta
old = red
new = green
[difftool]
prompt = false
[difftool "Kaleidoscope"]
cmd = ksdiff-wrapper git \"$LOCAL\" \"$REMOTE\"
[diff]
tool = Kaleidoscope
[filter "lfs"]
clean = git-lfs clean %f
smudge = git-lfs smudge %f
required = true