Skip to content
Myr

completions: fix mixed tab/spaces indentation (#1473)

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

These templates use 4 spaces for indentation, but some lines used tabs.

authored by Sebastiaan van Stijn · committed by GitHub · parent c7a4421 · Browse files · 3 files+11 added−11 removed
This commit

State

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

Trailers

  • Signed-off-by: Sebastiaan van Stijn <github@gone.nl>

Diff stats

3 files+11 added−11 removed

  • other:+11 added−11 removed

3 files+11 added−11 removed

modified:bash_completions.go+8 added-8 removed
236 unmodified lines
237 done < <(compgen -W "${noun_aliases[*]}" -- "$cur")238 fi239240 if [[ ${#COMPREPLY[@]} -eq 0 ]]; then241 if declare -F __%[1]s_custom_func >/dev/null; then242 # try command name qualified custom func243 __%[1]s_custom_func244 else245 # otherwise fall back to unqualified for compatibility246 declare -F __custom_func >/dev/null && __custom_func247 fi241 if declare -F __%[1]s_custom_func >/dev/null; then242 # try command name qualified custom func243 __%[1]s_custom_func244 else245 # otherwise fall back to unqualified for compatibility246 declare -F __custom_func >/dev/null && __custom_func247 fi248 fi249250 # available in bash-completion >= 2, not always present on macOS251 if declare -F __ltrim_colon_completions >/dev/null; then
56 unmodified lines
308 fi309310 # skip the argument to a two word flag311 if [[ ${words[c]} != *"="* ]] && __%[1]s_contains_word "${words[c]}" "${two_word_flags[@]}"; then312 __%[1]s_debug "${FUNCNAME[0]}: found a flag ${words[c]}, skip the next argument"312 __%[1]s_debug "${FUNCNAME[0]}: found a flag ${words[c]}, skip the next argument"313 c=$((c+1))314 # if we are looking for a flags value, don't show commands315 if [[ $c -eq $cword ]]; then316 commands=()
381 unmodified lines
modified:powershell_completions.go+2 added-2 removed
48 unmodified lines
49 # This happens because the $Command does not include the last space.50 if ($Command.Length -gt $CursorPosition) {51 $Command=$Command.Substring(0,$CursorPosition)52 }53 __%[1]s_debug "Truncated command: $Command"53 __%[1]s_debug "Truncated command: $Command"5455 $ShellCompDirectiveError=%[3]d56 $ShellCompDirectiveNoSpace=%[4]d57 $ShellCompDirectiveNoFileComp=%[5]d58 $ShellCompDirectiveFilterFileExt=%[6]d59 $ShellCompDirectiveFilterDirs=%[7]d6061 # Prepare the command to request completions for the program.61 # Prepare the command to request completions for the program.62 # Split the command at the first space to separate the program and arguments.63 $Program,$Arguments = $Command.Split(" ",2)64 $RequestComp="$Program %[2]s $Arguments"65 __%[1]s_debug "RequestComp: $RequestComp"
220 unmodified lines
modified:zsh_completions.go+1 added-1 removed
248 unmodified lines
249}250251# don't run the completion function when being source-ed or eval-ed252if [ "$funcstack[1]" = "_%[1]s" ]; then253 _%[1]s253 _%[1]s254fi255`, name, compCmd,256 ShellCompDirectiveError, ShellCompDirectiveNoSpace, ShellCompDirectiveNoFileComp,257 ShellCompDirectiveFilterFileExt, ShellCompDirectiveFilterDirs))
1 unmodified line