completion/bash-it: rename _bash-it-comp()

...to `_bash-it()`.

The norm is for the completion function for, e.g., `teh_cmd`. to be named with the same name and a prepended underscore, i.e. `_teh_cmd`. This alsö reduces namespace confusion, which will be relevant in a future patch.
This commit is contained in:
John D Pell
2022-01-09 21:30:24 -08:00
committed by John D Pell
parent 2f4ed49a71
commit 5f9a3f143f
2 changed files with 10 additions and 10 deletions

View File

@@ -6,7 +6,7 @@ function _compreply_candidates() {
read -d '' -ra COMPREPLY < <(compgen -W "${candidates[*]}" -- "${cur}")
}
function _bash-it-comp() {
function _bash-it() {
local cur prev verb file_type candidates suffix
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
@@ -83,9 +83,9 @@ function _bash-it-comp() {
}
# Activate completion for bash-it and its common misspellings
complete -F _bash-it-comp bash-it
complete -F _bash-it-comp bash-ti
complete -F _bash-it-comp shit
complete -F _bash-it-comp bashit
complete -F _bash-it-comp batshit
complete -F _bash-it-comp bash_it
complete -F _bash-it bash-it
complete -F _bash-it bash-ti
complete -F _bash-it shit
complete -F _bash-it bashit
complete -F _bash-it batshit
complete -F _bash-it bash_it