From ce23c7053355aa3bdae387959eeeb2a67ced2ad3 Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Fri, 20 Mar 2015 19:45:04 +0100 Subject: Don't autocomplete on 'insert'. --- bash-completion.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bash-completion.sh b/bash-completion.sh index 34ed969..81bee51 100644 --- a/bash-completion.sh +++ b/bash-completion.sh @@ -55,7 +55,9 @@ _icevault() { [ $(($OPTIND + 1)) -lt $cword ] && return local trim= - if [ -z "$cur" -a $OPTIND -eq $cword ] || [ -z "$cur" -a $(($OPTIND + 1)) -eq $cword -a "${words[OPTIND]}" = fill ]; then + if [ -z "$cur" -a $(($OPTIND + 1)) -eq $cword -a "${words[OPTIND]}" = insert ]; then + return + elif [ -z "$cur" -a $OPTIND -eq $cword ] || [ -z "$cur" -a $(($OPTIND + 1)) -eq $cword -a "${words[OPTIND]}" = fill ]; then cur="$(./icevault _geturi)"/ # get URI from webpage else cur=$(dequote "$cur") -- cgit v1.2.3