-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitconfig
More file actions
40 lines (40 loc) · 1.5 KB
/
.gitconfig
File metadata and controls
40 lines (40 loc) · 1.5 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
[core]
excludesfile = ~/.gitignore_global
quotepath = false
[user]
name = shirow ozawa
email = striderkein@users.noreply.github.com
[alias]
git = hub
b = branch
s = status -sb
co = checkout
cm = commit
cp = cherry-pick
ss = stash
sp = stash pop
sl = stash list
smu = submodule update
# staged diff
diffs = diff --cached
# view aliases list
al = config --get-regexp alias.*
# various log
log1 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(bold white)― %an%C(reset)%C(bold yellow)%d%C(reset)' --abbrev-commit --date=relative
log2 = log --pretty='format:%C(yellow)%h%Creset %C(magenta)%cd%Creset %s %Cgreen(%an)%Creset %Cred%d%Creset%C(black bold)%ar%Creset' --date=iso
log3 = log --graph --all --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(bold white)― %an%C(reset)' --abbrev-commit
# delete merged branch
# usage: git delete-merged-branch <branch_name>
# ex. usage: git delete-merged-branch develop
vacuum = "!f () { git checkout $1; git branch --merged|egrep -v '\\*|develop|dev|master|main'|xargs git branch -d; };f"
# get hash of HEAD
chash = rev-parse --short HEAD
cb = rev-parse --abbrev-ref HEAD
push-f = push --force-with-lease
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[color]
ui = auto