I was wondering if it's possible to make compgen
(complete
) only display possible options without completing.
for example with COMPREPLY=( $( compgen -W "--option1 --option2" -- $cur ))
--option1 --option2
will be suggested but --
will be added to my command line. Can I get rid of --
I took a look at compgen
's options but I cannot find the one that can help. I don't want to do any hack ( for eg displaying options first and then COMPREPLY=( $( compgen -W "" -- $cur ))
)