-
Notifications
You must be signed in to change notification settings - Fork 76
/
Copy path.gitconfig
40 lines (40 loc) · 1.46 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
[user]
name = Randy Lai
email = [email protected]
[github]
user = randy3k
[include]
path = .gitlocal
[alias]
alias = !git config --get-regexp 'alias.*' | colrm 1 6 | sed 's/[ ]/ = /'
amend = commit --amend --reset-author
br = branch
cl = clean -fd
co = checkout
cob = checkout -b
coo = checkout --orphan
fixup = !sh -c 'git commit --fixup=$(git rev-parse ${1:-HEAD})' -
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
qc = !git add -A && git commit -m
qf = !git add -A && git fixup && git ri HEAD^^
review = !sh -c 'git fetch origin pull/$1/head:pr/$1' -
ri = rebase --interactive --autosquash
shove = !REPO=$(git remote get-url origin | sed -n \"s|.*/\\(.*\\).git|\\1|p\") && bash -c \"test '$REPO'\" && git add -u && git commit -m \"Update $REPO at $(date -u)\" && git push
skip = update-index --skip-worktree
squash = !sh -c 'git commit --squash=$(git rev-parse ${1:-HEAD})' -
st = status -s
unadd = restore --staged
undo = !read -r -p 'Are you sure? [y/N] ' response && bash -c \"test $response = 'y'\" && git reset --hard
unskip = update-index --no-skip-worktree
upstream = rev-parse --abbrev-ref --symbolic-full-name @{u}
[color]
branch = auto
diff = auto
interactive = auto
status = auto
[rerere]
enabled = true
[core]
ignorecase = false
[init]
defaultBranch = main