-
Notifications
You must be signed in to change notification settings - Fork 105
/
git.aliases
executable file
·50 lines (45 loc) · 1.35 KB
/
git.aliases
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
#!/bin/bash
alias gs='git status'
alias ga='git add '
alias gd='git diff'
# alias gc='git commit -m'
alias gc='git cz'
# alias gc='git commit'
alias gll='git lg'
alias gull='git pull origin'
alias gush='git push origin'
alias gt='git checkout'
alias gfu='git fetch upstream'
alias gclean='git fetch --prune'
alias gitsynctag='git fetch --prune --tags'
# forgit
# alias gaa='git forgit add'
# alias gdd='git forgit diff'
# alias gll='git forgit log'
# alias gi='git forgit ignore'
# TODO: https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/git
# Git shortcuts
alias gb='git branch'
alias gba='git branch -a'
alias gbru='git remote prune origin'
alias gbd='git branch -D'
alias gcl='git clone'
alias gco='git checkout'
alias gcp='git cherry-pick'
alias gdi='git di'
alias gr='git rm'
alias gss='git status -s'
alias gl='git log'
alias gtd='git checkout develop'
alias gm='git merge --no-ff'
alias grv='git remote -v'
alias grsu='git remote set-url upstream'
#alias gd1='echo "git diff HEAD"; git diff HEAD'
#alias gd2='echo "git diff HEAD^"; git diff HEAD^'
#alias gsa='git submodule add'
#alias gsu='git submodule update --init'
#alias gup='git fetch && git rebase'
#alias gdv='git diff -w "$@" | vim -R -'
#alias gcount='git shortlog -sn'
#alias gexport='git archive --format zip --output'
#alias gmu='git fetch origin -v; git fetch upstream -v; git merge upstream/master'