Liliana Marie Prikler writes: […] >> +{ >> +    local command="${COMP_WORDS[1]}" >> +    case "$command" in >> +        discover) >> +            complitions="guix-daemon" >> +            mapfile -t COMPREPLY < <(compgen -W "$complitions" -- >> "${COMP_WORDS[$COMP_CWORD]}") >> +            ;; > Is there a reason to call the variable "complitions" rather than > "completions" No reason, it's a typo probably from autocompletion of my editor. :-) > or using an immediate value? Do you mean to use the following? --8<---------------cut here---------------start------------->8--- case "$command" in discover) mapfile -t COMPREPLY < <(compgen -W guix-daemon -- "${COMP_WORDS[$COMP_CWORD]}") ;; ... --8<---------------cut here---------------end--------------->8--- yes, this will work. No strong opinion on that, both ways would work for me. Regards, Oleg.