2024-05-28 14:21:08 +02:00
|
|
|
# Copyright (C) 2017 Hong Yongmin <https://revi.xyz>
|
2024-05-10 11:09:53 +02:00
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
2017-05-28 19:41:05 +02:00
|
|
|
[alias]
|
2024-05-10 11:10:01 +02:00
|
|
|
# some project uses `master` and some uses `main` for the default.
|
2024-06-08 09:25:13 +02:00
|
|
|
# since their first two letters are both ma, use the last char
|
|
|
|
# which is either `r` for master or `n` for main.
|
|
|
|
# a-d
|
|
|
|
# a-l
|
|
|
|
# a-p
|
|
|
|
# a-w
|
2024-05-09 13:43:01 +02:00
|
|
|
aal = add *
|
2024-06-08 09:25:13 +02:00
|
|
|
acm = commit -a -s
|
2024-05-11 09:47:33 +02:00
|
|
|
amend = commit --amend
|
2024-05-28 14:21:08 +02:00
|
|
|
amends = commit --amend -s
|
2024-06-08 09:25:13 +02:00
|
|
|
amendss = commit --amend -S -s
|
|
|
|
# arcd
|
|
|
|
# arcl
|
|
|
|
# arcp
|
|
|
|
# arcw
|
2024-05-28 14:21:08 +02:00
|
|
|
br = branch -v
|
|
|
|
brd = branch -d
|
|
|
|
brD = branch -D
|
2024-06-08 09:25:13 +02:00
|
|
|
cm = commit -s
|
|
|
|
cmt = commit -S -s
|
2024-05-28 14:21:08 +02:00
|
|
|
co = checkout
|
2024-06-08 09:25:13 +02:00
|
|
|
cob = checkout -b
|
2024-05-10 11:10:01 +02:00
|
|
|
com = !echo 'ERROR: use cor for master, and con for main.'
|
|
|
|
comn = checkout main
|
2024-05-28 14:21:08 +02:00
|
|
|
comr = checkout master
|
2024-05-21 08:47:37 +02:00
|
|
|
count = count-objects -vH
|
2024-06-08 09:25:13 +02:00
|
|
|
diffs = diff --staged
|
2024-05-28 14:21:08 +02:00
|
|
|
fa = fetch --all
|
|
|
|
fo = fetch origin
|
2024-06-08 09:25:13 +02:00
|
|
|
fup = fetch upstream
|
2024-05-28 14:21:08 +02:00
|
|
|
graph = log --pretty=format:\"%h %s\" --graph
|
|
|
|
osync = !echo 'ERROR: use osyncr for master, and osyncm for main.'
|
|
|
|
osyncn = rebase origin/main
|
|
|
|
osyncr = rebase origin/master
|
|
|
|
po= !echo 'ERROR: use por for master, and pon for main.'
|
|
|
|
pon = push origin main
|
|
|
|
por = push origin master
|
2024-06-08 09:25:13 +02:00
|
|
|
prod = !git checkout prod && git rebase origin/master && git push origin prod && git checkout master
|
2024-05-28 14:21:08 +02:00
|
|
|
st = status
|
2024-06-08 09:25:13 +02:00
|
|
|
staash = stash -a
|
2024-05-28 14:21:08 +02:00
|
|
|
usync = !echo 'ERROR: use usyncr for master, and usyncn for main.'
|
|
|
|
usyncn = rebase upstream/main
|
|
|
|
usyncr = rebase upstream/master
|
2024-05-09 13:43:01 +02:00
|
|
|
# below are non-git command, signified via `!` in the comment
|
|
|
|
# https://issuetracker.revi.xyz/u/gitalias
|
2024-05-11 09:47:43 +02:00
|
|
|
a-d = !arc diff
|
2024-06-08 09:25:13 +02:00
|
|
|
arcd = !arc diff
|
2024-05-11 09:47:43 +02:00
|
|
|
a-l = !arc land
|
2024-06-08 09:25:13 +02:00
|
|
|
arcl = !arc land
|
2024-05-11 09:47:43 +02:00
|
|
|
a-p = !arc patch
|
2024-06-08 09:25:13 +02:00
|
|
|
arcp = !arc patch
|
2024-05-11 09:47:43 +02:00
|
|
|
a-w = !arc work
|
2024-06-08 09:25:13 +02:00
|
|
|
arcw = !arc work
|