From ced0838598944c3555275545a718689faf2ba25b Mon Sep 17 00:00:00 2001 From: Jakub Roztocil Date: Fri, 26 Jun 2015 16:25:53 +0200 Subject: [PATCH] Converted tabs to spaces. --- httpie-completion.bash | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/httpie-completion.bash b/httpie-completion.bash index fdb4c67f..6201954b 100644 --- a/httpie-completion.bash +++ b/httpie-completion.bash @@ -1,22 +1,23 @@ -#!/bin/env bash +#!/usr/bin/env bash + _http_complete() { - local cur_word=${COMP_WORDS[COMP_CWORD]} - local prev_word=${COMP_WORDS[COMP_CWORD - 1]} + local cur_word=${COMP_WORDS[COMP_CWORD]} + local prev_word=${COMP_WORDS[COMP_CWORD - 1]} - if [[ "$cur_word" == -* ]]; then - _http_complete_options "$cur_word" - fi + if [[ "$cur_word" == -* ]]; then + _http_complete_options "$cur_word" + fi } complete -o default -F _http_complete http _http_complete_options() { - local cur_word=$1 - local options="-j --json -f --form --pretty -s --style -p --print - -v --verbose -h --headers -b --body -S --stream -o --output -d --download - -c --continue --session --session-read-only -a --auth --auth-type --proxy - --follow --verify --cert --cert-key --timeout --check-status --ignore-stdin - --help --version --traceback --debug" - COMPREPLY=( $( compgen -W "$options" -- "$cur_word" ) ) + local cur_word=$1 + local options="-j --json -f --form --pretty -s --style -p --print + -v --verbose -h --headers -b --body -S --stream -o --output -d --download + -c --continue --session --session-read-only -a --auth --auth-type --proxy + --follow --verify --cert --cert-key --timeout --check-status --ignore-stdin + --help --version --traceback --debug" + COMPREPLY=( $( compgen -W "$options" -- "$cur_word" ) ) }