Skip to content
Myr

Do not add a space after a single flag completion (#625)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Eric Paris · committed by GitHub · parent be77323 · Browse files · 1 file+6 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+6 added−0 removed

  • other:+6 added−0 removed

1 file+6 added−0 removed

modified:bash_completions.go+6 added
134 unmodified lines
135 # available in bash-completion >= 2, not always present on macOS136 if declare -F __ltrim_colon_completions >/dev/null; then137 __ltrim_colon_completions "$cur"138 fi139140 # If there is only 1 completion and it is a flag with an = it will be completed141 # but we don't want a space after the =142 if [[ "${#COMPREPLY[@]}" -eq "1" ]] && [[ $(type -t compopt) = "builtin" ]] && [[ "${COMPREPLY[0]}" == --*= ]]; then143 compopt -o nospace144 fi145}146147# The arguments should be in the form "ext1|ext2|extn"148__%[1]s_handle_filename_extension_flag()
401 unmodified lines