Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Interrupting globs (Re: Something rotten in tar completion)



On Dec 5,  3:17pm, Jeremie Roquet wrote:
} Subject: Re: Interrupting globs (Re: Something rotten in tar completion)
}
} > -    if (!q)
} > +    if (!q || errflag)
} 
} I've no Idea if the expansion of something like "ls /a/b/c<tab>" to
} "ls /aaaaa/bbbbbb/cccccc/" is related to this code, but it seems to
} have zero impact there: I'm still unable to interrupt the horribly
} slow expansion using ctrl+c.

Do you have a matcher-list zstyle?

In the "trap ... INT" formulation of the trap in _main_complete, the
loop that retries each of the completers for every element of the
matcher-list does not get interrupted by ^C, even though the pass
that is in progress when you interrupt does stop.

This means you have to hit ^C at least once for every matcher, and maybe
also once for every completer that does something time-consuming.

The formulation using TRAPINT() blows all the way out of _main_complete,
which certainly stops the completion at that point but also screws up
all sorts of cleanup that _main_complete would normally do, such as
setting up _lastcomp, and restoring the values of ZLS_COLORS and the
_comppostfuncs array.



Messages sorted by: Reverse Date, Date, Thread, Author