Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Anyone familiar with auto-fu.zsh project?
- X-seq: zsh-users 23467
- From: Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx>
- To: Eric Freese <ericdfreese@xxxxxxxxx>
- Subject: Re: Anyone familiar with auto-fu.zsh project?
- Date: Mon, 11 Jun 2018 07:24:57 +0200
- Cc: Zsh Users <zsh-users@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=HklURLpSRYHStjGTG9vz3RQCZ4WD4uFiTC8L226kXA4=; b=Iw8ouGFvyQa1pg7EDU5SNutp2KwMs3O9BzLwO+x1tjqcuZAnKb+dMiS0LFPCqHzf/J 7xC5abpl0qAHMiw3WYBtMxI8QRAYbzA06HPBmv547moiiQpW2bndQ3nWIj0R70Lic8Zd C1AUciaPz9CtATWpJnojJHVAGzQvvtyAMO5nGe74TkZQiTdb1NuC+xZH4pxCjPVn1+/j iVOMAWSocJyUDPhYJ6N9gEX0T4MgP7JYRUYn0anLu3jRm5aXr0fikTf2U0w4+kjYwKIH cHwXS7l37Cs97LQMg93LDQXzp7KOHdx7nVmXKdMvjfVFLn/rLm+RWFPjlYCVj2Y/csUI hTEg==
- In-reply-to: <CAAikoAK3SdfCmK=sEpfG=DP2dEvcVL1V-rw1hRiQLGzuvE=ZvA@mail.gmail.com>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- List-unsubscribe: <mailto:zsh-users-unsubscribe@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <CAKc7PVCu_L1Sgsp281KuvXUuMkkGvxs8D1dJAmVcBxm7RnJLwA@mail.gmail.com> <CAAikoA+iGXVQXGfRP-RepefEc+FAG0+brAVcPjp5p=969+j7Kg@mail.gmail.com> <CAKc7PVDe29JSCEeXU7F_dqG5a7TvfTz=sP3=4nDLOm1jQOxFnA@mail.gmail.com> <CAAikoAK3SdfCmK=sEpfG=DP2dEvcVL1V-rw1hRiQLGzuvE=ZvA@mail.gmail.com>
Hello,
I've just implemented async feature without using zpty. From what I
saw zsh-autosuggestions uses zpty to look-up the suggestion. Maybe it
has some drawbacks and you would be interested in using <( ) instead
of zpty (it's probably still required to capture completions, though)?
It's similar to using zpty:
exec {PCFD}< <(-fast-highlight-check-path)
zle -F -w "$PCFD" fast-highlight-check-path-handler
-fast-highlight-check-path-handler() {
if read -r -u "$PCFD" line; then
...
fi
zle -F ${PCFD}
exec {PCFD}<&-
}
<( ) process is automatically disowned, I've used it in 2 projects and
it works without problems, very robust. The effect:
https://asciinema.org/a/V18uHIn2BR0OVfRsmxyqkVi7K
--
Best regards,
Sebastian Gniazdowski
Messages sorted by:
Reverse Date,
Date,
Thread,
Author