-
Notifications
You must be signed in to change notification settings - Fork 1
/
gitconfig
67 lines (67 loc) · 2.56 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
[user]
name = Michael Lee
email = [email protected]
[alias]
co = checkout
update = checkout
up = checkout
ci = commit
st = status -uno
ch = diff --name-status -r
ff = "!f() { git checkout ${1:-.} && git pull --ff-only; }; f"
fff = !sh -c 'echo -n "Are you sure [Y/n]? " && read ans && [[ "$ans" != "n" ]] && ( git checkout . && git clean -f -d . && git pull --ff-only ) || echo Ok'
ff-all = !git br --list | awk '{print $NF}' | xargs -n1 -I{} sh -c 'git checkout {} && git pull --ff-only'
ls = log --graph --date=short --pretty='%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all --since='30 days ago'
branches = !git branch | awk '{print $NF}'
bm = branch
br = branch
br-show = branch -av
amend = commit -a --amend --no-edit
subpull = submodule foreach --recursive git pull origin master
stash-diff = stash show --pretty=raw
recent-hist = log --graph --date=short --pretty='%Cred%h %Cgreen%ar%Creset | %s%C(yellow)%d %C(bold blue)[%an]%Creset' --since='14 days ago'
resolve-rebase = rebase --continue
hist = log --graph --date=short --pretty='%C(red)%>(8)%h %C(green)%>(12)%ar%C(reset) | %s%C(yellow)%d %C(bold blue)[%an]%Creset'
hist-stat = log --graph --date=short --pretty='%C(red)%>(8)%h %C(green)%>(12)%ar%C(reset) | %C(bold blue)[%an]%Creset%C(yellow)%d%Creset%n%s' --stat
hist-all = log --graph --date=short --pretty='%C(red)%>(8)%h %C(green)%>(12)%ar%C(reset) | %s%C(yellow)%d %C(bold blue)[%an]%Creset' --all
sl = log --graph --date=short --pretty='%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all --since='30 days ago'
short = log --graph --date=short --pretty='%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all
type = cat-file -t
dump = cat-file -p
flash = !git stash && git pull --rebase ${@} && git stash pop && echo "Flashed "
shelve = stash
unshelve = stash pop
w-add = !sh -c 'git diff -w --no-color "$@" | git apply --cached --ignore-whitespace' -
alias = config --get-regexp '^alias\\.'
[core]
excludesfile = ~/.gitignore
editor = emacs
[color]
branch = auto
diff = auto
status = auto
interactive = always
grep = always
[color "branch"]
local = yellow
remote = green
current = yellow reverse
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "status"]
added = yellow
changed = green
untracked = cyan
[help]
autocorrect = 1
[merge]
conflictstyle = diff3
[push]
default = current
[branch]
autosetuprebase = always
[init]
defaultBranch = main