Skip to content

Commit c8d5e3f

Browse files
author
Lars Gohlke
committed
adds glab bash completion
1 parent 6c839d6 commit c8d5e3f

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tools/git.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,3 +135,13 @@ function git_clean_merged_branches() {
135135
done
136136
}
137137
export -f git_clean_merged_branches
138+
139+
140+
if [[ -z $GLAB_COMPLETION_INSTALLED ]]; then
141+
if command -v glab > /dev/null; then
142+
# see https://docs.gitlab.com/cli/completion/#bash
143+
# shellcheck disable=SC1090
144+
source <(glab completion -s bash)
145+
export GLAB_COMPLETION_INSTALLED=1
146+
fi
147+
fi

0 commit comments

Comments
 (0)