Hey! I get stuck trying to implement completion script for strings containing
two parts for completion delimited by '%' sign. For example, `cmd opt%arg`.
The problem is that, if i hit tab key, when cursor is behind delimeter, bash
eats first part of string leaving `cmd arg`. I just can't unders
On 05/23/2011 02:45 AM, Igor Murzov wrote:
> Hey! I get stuck trying to implement completion script for strings containing
> two parts for completion delimited by '%' sign. For example, `cmd opt%arg`.
> The problem is that, if i hit tab key, when cursor is behind delimeter, bash
> eats first pa
On Mon, May 23, 2011 at 03:45:39AM +0400, Igor Murzov wrote:
> Hey! I get stuck trying to implement completion script for strings containing
> two parts for completion delimited by '%' sign. For example, `cmd opt%arg`.
> The problem is that, if i hit tab key, when cursor is behind delimeter, bas
On Mon, May 23, 2011 at 11:39:45PM +0300, Ville Skyttä wrote:
> On 05/23/2011 02:45 AM, Igor Murzov wrote:
> > Hey! I get stuck trying to implement completion script for strings
> > containing
> > two parts for completion delimited by '%' sign. For example, `cmd
> > opt%arg`.
> > The problem i
On Mon, May 23, 2011 at 10:57:14PM +0200, Raph wrote:
[...]
> I'm interested too in knowing how to deals with COMP_WORDBREAK,
> (especially using properly the API)
May be seen as a thread hijack but I think this is related:
The attached completion, is the only way I found to have a consistent
comp
On 05/23/2011 11:57 PM, Raph wrote:
> and I'm interested too in knowing how to deals with COMP_WORDBREAK,
> (especially using properly the API)
I think the API facilities we have for this are the -n arguments to
_get_comp_words_by_ref and _init_completion. I don't claim to
understand anywhere ne
В сообщении от 24 мая 2011 00:39:45 автор Ville Skyttä написал:
> On 05/23/2011 02:45 AM, Igor Murzov wrote:
> > Hey! I get stuck trying to implement completion script for strings
> > containing two parts for completion delimited by '%' sign. For example,
> > `cmd opt%arg`. The problem is that, if
On 05/25/2011 11:52 AM, Igor Murzov wrote:
> upgradepkg old_package_name%new_package_name
> I want to handle this notation in completion. I need to complete filenames
> and
> directories after '%'. I wrote two variants of completion function, but none
> of them works as expected. Actually, pr
В сообщении от 25 мая 2011 21:59:30 автор Ville Skyttä написал:
> Maybe try to add % to it instead and see if that leads to something useful?
>
> $ bash --norc
> $ echo "$COMP_WORDBREAKS"
>
> "'@><=;|&(:
Adding % to COMP_WORDBREAKS indeed solves the issue. I suppose that applying
Raphaël's patc
I can't understand how $COMP_WORDBREAKS works and why quotes on command line
give such a weird result. Test function is following:
--
_zz()
{
echo -e "\n* $COMP_CWORD:"
for (( i=0; i <= COMP_CWORD; i++ )); do
echo "[${COMP_WORDS[i]}]"
done
} && complete
10 matches
Mail list logo