You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
alias gg='git log --graph --pretty=format:'\''%C(bold)%h%Creset%C(magenta)%d%Creset %s %C(yellow)<%an> %C(cyan)(%cr)%Creset'\'' --abbrev-commit --date=relative'
72
72
alias ggf='git log --graph --date=short --pretty=format:'\''%C(auto)%h %Cgreen%an%Creset %Cblue%cd%Creset %C(auto)%d %s'\'''
73
73
alias ggs='gg --stat'
74
+
alias ggup='git log --branches --not --remotes --no-walk --decorate --oneline'# FROM https://stackoverflow.com/questions/39220870/in-git-list-names-of-branches-with-unpushed-commits
74
75
alias gll='git log --graph --pretty=oneline --abbrev-commit'
75
76
alias gnew='git log HEAD@{1}..HEAD@{0}'# Show commits since last pull, see http://blogs.atlassian.com/2014/10/advanced-git-aliases/
76
77
alias gwc='git whatchanged'
@@ -104,15 +105,15 @@ alias gp='git push'
104
105
alias gpd='git push --delete'
105
106
alias gpf='git push --force'
106
107
alias gpo='git push origin HEAD'
107
-
alias gpom='git push origin master'
108
+
alias gpom='git push origin $(get_default_branch)'
108
109
alias gpu='git push --set-upstream'
109
110
alias gpunch='git push --force-with-lease'
110
111
alias gpuo='git push --set-upstream origin'
111
112
alias gpuoc='git push --set-upstream origin $(git symbolic-ref --short HEAD)'
112
113
113
114
# pull
114
115
alias gl='git pull'
115
-
alias glum='git pull upstream master'
116
+
alias glum='git pull upstream $(get_default_branch)'
116
117
alias gpl='git pull'
117
118
alias gpp='git pull && git push'
118
119
alias gpr='git pull --rebase'
@@ -128,9 +129,9 @@ alias grm='git rm'
128
129
# rebase
129
130
alias grb='git rebase'
130
131
alias grbc='git rebase --continue'
131
-
alias grm='git rebase master'
132
-
alias grmi='git rebase master -i'
133
-
alias gprom='git fetch origin master && git rebase origin/master && git update-ref refs/heads/master origin/master'# Rebase with latest remote master
132
+
alias grm='git rebase $(get_default_branch)'
133
+
alias grmi='git rebase $(get_default_branch) -i'
134
+
alias gprom='git fetch origin $(get_default_branch) && git rebase origin/$(get_default_branch) && git update-ref refs/heads/$(get_default_branch) origin/$(get_default_branch)'# Rebase with latest remote
134
135
135
136
# reset
136
137
alias gus='git reset HEAD'
@@ -174,7 +175,7 @@ alias gsu='git submodule update --init --recursive'
0 commit comments