summaryrefslogtreecommitdiff
path: root/plugins/git/git.plugin.zsh
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/git/git.plugin.zsh')
-rw-r--r--plugins/git/git.plugin.zsh6
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/git/git.plugin.zsh b/plugins/git/git.plugin.zsh
index d053a7638..48937cb83 100644
--- a/plugins/git/git.plugin.zsh
+++ b/plugins/git/git.plugin.zsh
@@ -128,11 +128,13 @@ alias gba='git branch --all'
alias gbd='git branch --delete'
alias gbD='git branch --delete --force'
-# Copied and modified from James Roeder (jmaroeder) under MIT License
-# https://github.com/jmaroeder/plugin-git/blob/216723ef4f9e8dde399661c39c80bdf73f4076c4/functions/gbda.fish
function gbda() {
git branch --no-color --merged | command grep -vE "^([+*]|\s*($(git_main_branch)|$(git_develop_branch))\s*$)" | command xargs git branch --delete 2>/dev/null
+}
+# Copied and modified from James Roeder (jmaroeder) under MIT License
+# https://github.com/jmaroeder/plugin-git/blob/216723ef4f9e8dde399661c39c80bdf73f4076c4/functions/gbda.fish
+function gbds() {
local default_branch=$(git_main_branch)
(( ! $? )) || default_branch=$(git_develop_branch)