-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitconfig
26 lines (26 loc) · 1.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
[alias]
al = config --get-regexp alias
co = checkout
ci = commit
ca = commit --amend --no-edit
cae = commit --amend
can = commit --amend --no-edit --no-verify
cn = commit --no-verify
st = status
br = branch
pu = push
pf = push --force-with-lease
po = "!git push --set-upstream origin \"$(git rev-parse --abbrev-ref HEAD)\"" # push new branch to origin
hs = log --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short # history graph?
hd = log -p --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short # history diff?
gh = log --graph --decorate --oneline --all # git graph
branch-by-author = for-each-ref --format=' %(authorname) %09 %(refname)' --sort=authorname # get all branches by user
find-old-file = log --full-history --
prune-origin = remote prune origin # Clear origin branches
pr = remote prune # Clear remote passed branches
sh = "!f() { git log -S '$2' -- $1; }; f" # search history: look for string ($2) in file ($1) history
sl = log --grep # search logs: look for string ($1) in commit text
[user]
name = Jonathon Gardner
[core]
editor = vim