-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitconfig
51 lines (46 loc) · 2.09 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
[core]
editor = vim
pager = 'less'
[user]
email = valdeir.naval@gmail.com
name = Valdeir S.
[log]
showSignature = true
[man]
viewer = man
[alias]
ls = log --graph --pretty=format:'%Cred%h%Creset: %s %C(yellow)%d%Creset - %C(cyan)By %an <%ae>%Creset %Cgreen(%ar)%Creset'
lg = log --graph --color=always --pretty=format:'%C(yellow)commit %H%Creset%C(auto)%d%Creset%nAuthor: %cn <%ce>%nDate: %cd %C(12)(%cr)%Creset%n%n %s%n%n%w(121,4,4)%b%+N'
ci = commit -sS
ca = commit -asS
caa = !git add -A && git commit -sS
ds = diff --patch-with-stat
cii = commit -psS
go = "!f() { git switch \"$1\"; }; f"
aliases = config --get-regexp alias
contribs = shortlog --summary --numbered --email
whoami = "!n() { echo \"$(git config user.name) <$(git config user.email)>\"; }; n"
fc = "!s() { git log --color=always --oneline --date-order -S$1; }; s"
fm = "!s() { git log --oneline --grep=$1; }; s"
v5 = !git config user.name 'Valdeir S.' && git config user.email "valdeir@v5market.com"
master = switch master
main = switch main
develop = switch develop
zip = "!a() { filename=$(basename $(pwd)__$(date +%F__%H_%M_%S).zip); git archive --format zip -o $(echo $filename) -9 ${1:-HEAD}; echo $filename; }; a"
web = instaweb -d python
ui = gui
bc = branch --show-current
b = branch --format='%(color:red)%(objectname:short=9)%(color:reset) %(color:cyan)%(align:40)By %(committername) %(committeremail)%(end)%(color:reset) %(color:green)%(align:14)%(committerdate:relative)%(end)%(color:reset) %(if)%(HEAD)%(then)%(color:blue bold italic)%(else)%(end)%(refname:lstrip=2)%(color:reset)'
bl = "!b() { \
git branch --format \"%(refname:strip=2)\" | while read -r branch_name; do \
branch_description=$(git config --get \"branch.$branch_name.description\"); \
git b --list \"$branch_name\"; \
if [ -n \"$branch_description\" ]; then \
echo \"\nDescription:\"; \
git config --get \"branch.$branch_name.description\" | sed 's/^/ /g'; \
fi; \
done; \
}; b"
prev = switch -
[init]
defaultBranch = main