Le Vendredi 26 Juillet 2002 08:23, Sebastian Dransfeld a �crit :
> This one doesn't work:
> _filedir_xspec()
> {
>         local IFS cur xspec
>
>         IFS=$'\t\n'
>         COMPREPLY=()
>         cur=${COMP_WORDS[COMP_CWORD]}
>
>         _expand || return 0
>
>         # get first exclusion compspec that matches this command
>         xspec=$( sed -ne '/ '${1##*/}'/{p;q;}' $BASH_COMPLETION )
>         # prune to leave nothing but the -X spec
>         xspec=${xspec#*-X }
>         xspec=${xspec%% *}
>
>         COMPREPLY=( $( eval compgen -f -X "$xspec" -- \"${cur#[\`\"\']}\" )
> \ $( compgen -d -- $cur ) )
> }
>
> With this test:
> sebastid@tl-dhcp-100:~/src/test/simplex$ time -p ./test-bash: eval: line
> 1: unexpected EOF while looking for matching `)'
>
> test     test.c   test.o   test.sh
>
> It seems like xspec will contain: 'COMPREPLY=('
Even if i'm involved in some mdk-specific functions, main developper for bash 
completion is Ian Macdonald. All bug reports should be sent to him directly.
-- 
Guillaume Rousse <[EMAIL PROTECTED]>
GPG key http://lis.snv.jussieu.fr/~rousse/gpgkey.html

Reply via email to