-
Notifications
You must be signed in to change notification settings - Fork 2
/
.gitconfig
32 lines (32 loc) · 1.34 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
[push]
deafult = matching
default = matching
[alias]
search-hash = !git log --graph --pretty=format:'%d %an: %s %ar %h' | peco | awk -F ' ' '{ print $NF }'
alias = !git config --get-regexp '^alias\\.' | sed 's/alias\\.\\([^ ]*\\) \\(.*\\)/\\1\\\t => \\2/' | sort
a = !git add -A && git status
au = !git add -u && git status
f = "!git ls-files | grep -i"
diffr = "!f() { git diff "$1"^.."$1"; }; f"
dr = "!f() { git diff "$1"^.."$1"; }; f"
lc = "!f() { git ll "$1"^.."$1"; }; f"
pb = !git co -b `git branch -a | peco --query 'remotes/ ' --prompt 'GIT REMOTE BRANCH>' | head -n 1 | sed 's/^\\*\\s*//' | sed 's/remotes\\/[^\\/]*\\/\\(\\S*\\)/\\1 \\0/'`
cam = commit --amend
wip = commit -m 'wip'
co = checkout
cob = "!f() { git checkout -b "$1" && git branch; }; f"
cm = commit
st = status
stt = status -uno
br = branch
ll = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat
graph = log --graph --date=short --decorate=short --pretty=format:'%Cgreen%h %Creset%cd %Cblue%cn %Cred%d %Creset%s'
gr = log --graph --date=short --decorate=short --pretty=format:'%Cgreen%h %Creset%cd %Cblue%cn %Cred%d %Creset%s'
cancel = reset --soft HEAD^
zip = !git archive --format=zip HEAD > `git symbolic-ref --short HEAD`.zip
drag = pull --rebase
[core]
editor = vim
[user]
email = antyobido@gmail.com
name = kurenaif