From fe7f117ad22c1f2884c47cb961ea33f1c88206a4 Mon Sep 17 00:00:00 2001 From: Sylvain Joubert Date: Thu, 4 Aug 2016 18:59:21 +0200 Subject: bash-completion: Fix cmake -E lookup In case of long ' ' the description text is wrapped and indented on the next line. Avoid taking these lines into account by explicitly requiring the third character to be a non-space. --- Auxiliary/bash-completion/cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Auxiliary/bash-completion/cmake b/Auxiliary/bash-completion/cmake index 6061129..0a862fa 100644 --- a/Auxiliary/bash-completion/cmake +++ b/Auxiliary/bash-completion/cmake @@ -102,7 +102,7 @@ _cmake() ;; -E) COMPREPLY=( $( compgen -W "$( cmake -E help |& sed -n \ - '/^ /{s|^ \([^ ]\{1,\}\) .*$|\1|;p}' 2>/dev/null )" \ + '/^ [^ ]/{s|^ \([^ ]\{1,\}\) .*$|\1|;p}' 2>/dev/null )" \ -- "$cur" ) ) return ;; -- cgit v0.12