-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgit_aliases
More file actions
57 lines (52 loc) · 1.54 KB
/
git_aliases
File metadata and controls
57 lines (52 loc) · 1.54 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
[alias]
comit = commit
amend = commit --amend
ap = add --patch
fe = fetch
s = status --short
d = diff
check = diff --check
ds = diff --stat
dw = diff --word-diff
dm = diff master
dms = diff master --stat
dc = diff --cached
dcs = diff --cached --stat
dp = diff HEAD^ HEAD
dps = diff HEAD^ HEAD --stat
me = merge
mom = merge origin/master
mt = mergetool
rom = rebase origin/master
rc = rebase --continue
dom = diff origin/master
# Quick switch to main/master
master = switch --no-guess master
main = switch --no-guess main
# New style branch switching
sw = switch
swc = switch --create
# Old style branch switching
co = checkout
cob = checkout -b
cop = checkout --patch
cp = cherry-pick
st = status
unstage = rm --cached
br = branch -vv
brr = branch --remotes -vv
l1 = log -n 1 --oneline --decorate=no
lg = log --graph --pretty=medium --abbrev-commit --date=local
lgb = log --graph --pretty=medium --abbrev-commit --date=local --branches --all
lol = log --graph --oneline
lola = log --graph --oneline --all
l = log --graph --pretty=custom
la = log --graph --pretty=custom --all
# Show files ignored by git:
ign = ls-files -o -i --exclude-standard
# Show verbose output about tags, branches or remotes
tags = tag -l
branches = branch -a
remotes = remote -v
# Prune branches
cleanup = !git branch --merged | grep -v \"\\*\\|master\\|main\" | xargs -n1 git branch --delete