-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitconfig
92 lines (92 loc) · 2.93 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
[user]
email = [email protected]
name = Gilles Lepretre
[color]
ui = true
[core]
editor = vi
excludesfile = ~/.gitignore_global
attributesfile = ~/.gitattributes
[alias]
aa = add --all
aliases = config --get-regexp alias
ap = add --all --patch
author-commits = shortlog -s -n -e
author-lines = !git ls-tree -r -z --name-only HEAD | xargs -0 -n1 git blame --line-porcelain HEAD | grep '^author ' | sort | uniq -c | sort -nr | sed 's/author //'
ca = commit --amend
caf = commit --amend --no-edit
cav = commit --amend --verbose
cb = checkout -b
cm = commit -m
cmn = commit --no-verify -m
co = checkout
count = rev-list --count
cp = cherry-pick
cv = commit -v
cvn = commit -v --no-verify
dc = difftool --cached
df = difftool -p
dm = difftool master
dms = diff master --stat
dr = !ANCESTOR=$(git merge-base HEAD origin/master) && git icdiff $ANCESTOR..HEAD
drs = !ANCESTOR=$(git merge-base HEAD origin/master) && git diff --stat $ANCESTOR..HEAD
ds = diff --stat
dsc = diff --stat --cached
fa = !git fetch && git fetch --tags
fap = !git fetch --prune && git fetch --tags
last = !git fa && git log --all -n 1 --pretty=format:%H
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative
pr = pull --rebase
pt = push --tags
pu = !CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD) && git push -u origin $CURRENT_BRANCH
rbi = rebase -i
restash = stash store
root = rev-parse --show-toplevel
rph = rev-parse HEAD
rpm = rev-parse master
sa = !git stash apply && git diff --full-index --binary > .latest-stash
save = !CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD) && git stash push -u -m wip-$CURRENT_BRANCH
sd = "!f(){ echo \"Drop stash? (y/N)\"; read answer; if [ \"$answer\" = \"y\" ]; then git stash drop \"$@\"; else echo \"Stash drop aborted\"; fi; }; f"
sh = !GIT_EXTERNAL_DIFF=difft git show HEAD --ext-diff
show-icdiff = !git icdiff HEAD^..HEAD
sk = stash -k
sm = !git submodule init && git submodule sync && git submodule update --init --recursive --force
sp = stash pop
ss = stash show -p
st = status
su = !git apply -R .latest-stash && rm .latest-stash
undo = reset --soft HEAD^
up = !LAST=$(git last) && BRANCH=$(git name-rev --name-only $LAST | cut -d '/' -f3-) && git checkout $BRANCH
[push]
default = simple
[init]
defaultBranch = main
[commit]
gpgSign = true
[credential]
helper = cache --timeout=600
[credential "https://github.com"]
username = glepretre
[format]
pretty = fuller
[tig "bind"]
generic = D !git icdiff %(commit)^!
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[merge]
ff = false
[pull]
ff = only
[diff]
tool = difftastic
[difftool]
prompt = false
[difftool "difftastic"]
cmd = difft "$LOCAL" "$REMOTE"
[pager]
difftool = true
[branch]
sort = -committerdate