-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitconfig
73 lines (73 loc) · 2.4 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
[color]
diff = auto
status = auto
branch = auto
interactive = auto
ui = auto
[core]
excludesfile = /Users/sh-murakami/.gitignore_global
editor = vim -f
pager = diff-so-fancy | less --tabs=4 -RFX
[diff]
tool = nvimdiff
# tool = nvr
[difftool]
prompt = false
[difftool "nvimdiff"]
cmd = nvim -d \"$LOCAL\" \"$REMOTE\"
[difftool "nvr"]
cmd = nvr -s -d $LOCAL $REMOTE
[difftool "sourcetree"]
cmd = opendiff \"$LOCAL\" \"$REMOTE\"
path =
[merge]
tool = nvimdiff
[mergetool]
prompt = false
[difftool "nvimdiff"]
cmd = nvim -d \"$LOCAL\" \"$REMOTE\"
[mergetool "nvr"]
cmd = nvr -s -d $LOCAL $REMOTE $BASE $REMOTE $MERGED -c 'wincmd J | wincmd ='
[mergetool "sourcetree"]
cmd = /Applications/SourceTree.app/Contents/Resources/opendiff-w.sh \"$LOCAL\" \"$REMOTE\" -ancestor \"$BASE\" -merge \"$MERGED\"
trustExitCode = true
[user]
name = shu22203
email = [email protected]
[commit]
template = /Users/shu/.stCommitMsg
[ghq]
root = ~/src
[url "github:"]
InsteadOf = https://github.com/
InsteadOf = [email protected]:
[alias]
# http://oli.jp/2012/git-powerup/
# http://blog.blindgaenger.net/advanced_git_aliases.html
alias = !git config --list | grep 'alias\\.' | sed 's/alias\\.\\([^=]*\\)=\\(.*\\)/\\1\\\t => \\2/' | sort
b = branch
ba = branch -a
bs = branch -vv
ci = commit
cim = commit -m
co = checkout
cob = checkout -b
d = diff
dc = diff --cached
ds = diff --staged
f = fetch --prune
fetch-pulls = fetch origin +refs/pull/*:refs/remotes/pull/*
fs = !git f && git su
ignore = !([ ! -e .gitignore ] && touch .gitignore) | echo $1 >> .gitignore
info = remote show origin
l = log --graph -n 20 --pretty=format:'%C(yellow)%h%C(cyan)%d%Creset %s %C(green)- %an, %cr%Creset'
ll = log --stat --abbrev-commit
ln = log --graph -n 20 --pretty=format:'%C(yellow)%h%C(cyan)%d%Creset %s %C(green)- %an, %cr%Creset' --name-status
lp = log --oneline -n 20 -p
ls = log --stat --abbrev-commit -n 1 # display previous log
m = merge --no-ff
openpr = "!f() { hub browse -- `git log --merges --oneline --reverse --ancestry-path $1...master | grep 'Merge pull request #' | head -n 1 | cut -f5 -d' ' | sed -e 's%#%pull/%'`; }; f"
p = pull --prune
s = status --short --branch
showpr = !"f() { git log --merges --oneline --reverse --ancestry-path $1...master | grep 'Merge pull request #' | head -n 1; }; f"
st = status