diff --git a/modules/git/functions/_git-branch-delete-interactive b/modules/git/functions/_git-branch-delete-interactive new file mode 100644 index 0000000..e102f80 --- /dev/null +++ b/modules/git/functions/_git-branch-delete-interactive @@ -0,0 +1,3 @@ +#compdef git-branch-delete-interactive + +words[1]=(git branch); (( CURRENT++ )); service=git; _git diff --git a/modules/git/functions/git-branch-delete-interactive b/modules/git/functions/git-branch-delete-interactive index 9a7f6a3..2eb0985 100644 --- a/modules/git/functions/git-branch-delete-interactive +++ b/modules/git/functions/git-branch-delete-interactive @@ -1,6 +1,6 @@ # vim:et sts=2 sw=2 ft=zsh local -a remotes -if (( ${*[(I)-r]} || ${*[(I)--remotes]} )); then +if (( ${*[(I)(-r|--remotes)]} )); then remotes=(${^*:#-*}) else remotes=(${(f)"$(command git rev-parse --abbrev-ref ${^*:#-*}@{u} 2>/dev/null)"})