From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8358 invoked by alias); 11 Jun 2018 09:47:15 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: List-Unsubscribe: X-Seq: 23469 Received: (qmail 17416 invoked by uid 1010); 11 Jun 2018 09:47:15 -0000 X-Qmail-Scanner-Diagnostics: from mail-oi0-f49.google.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(209.85.218.49):SA:0(-1.9/5.0):. Processed in 1.179488 secs); 11 Jun 2018 09:47:15 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_PASS, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: sgniazdowski@gmail.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | 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:content-transfer-encoding; bh=wzs9RX4chhOevUFPAclm6gjT2n88CSFWTuIw2qcLEt0=; b=dlo30QpfZ1ZZDobayolWkCTQDwtVOahYPDJq/K6qBUpkEt+RNQerEqy8/GJAuakjQy f6cVdROrzOWTxaXQy3FdGuH/hmFHMFxljDgsvoEI2OKx2Sq1zx8ey+Z58LEq5TP8Q38l 3Em8WALJaEC4yu/IzDpiRKToV0OcV4gp52jRNTMIDJUjHRbmLa+2tuw6PfPcTVzz/LZA oBuKFW5PL/CFXLt+j9ivoL4RpiK4GXS6NpDMHBIP9/owXQu9j8/Hae6P1F7AXe+avk9b Ef/xQaStQMU+KCexGuvTxMNiPYOaQcrJIJ8PlKIBJogDxO0NFBoKXHL7dfnKEyF4KtFb CEXA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=wzs9RX4chhOevUFPAclm6gjT2n88CSFWTuIw2qcLEt0=; b=EVEYlE9v2QB4/zztv+zWKqlvxF7zSCOUI/V9jDV7w+iQAQRWd0Kd5hpp+eRSdJJHyw JzVGt26HYAtSnPIr1+8o6iqTP9NiEiLtHUTzfLvFy3nK3/HTnHdO5huzFD7DJfxOrcXL wk6QjE2jlvw8iDELL7W06rjG8r2njYGDE1E4tlp569TrfWCgZcU0HcqI5zzMh46icCGq 22k/2iNKk/zTxofKykXtGfBjxWqpG8YkZHyhwLSiqYJ+xVKLuZiKGheIuwbK9gKdKOQG XDezulnJhb49nybvxZEV4gWsTsAoE82pNXzRuVlRNSG+v382vvgGrD7/ZaL4AUPmKn3d ZHpw== X-Gm-Message-State: APt69E1uU/5assVi8KZp39O8hxrczKsF8vDyoFm/s/UVqA+lrk2Zh0c5 4EGcTSaFDdY6CqmZz4oTisJLcmy6ztZezfBFDkc= X-Google-Smtp-Source: ADUXVKIu9caOR0f8FzMUjzKgYirtwwu/I9MDdQ6zSpQlA1nFOZa5YzX+p3RhQB/Tm3JJXGMfIygHECAwcC1V1cXI3yg= X-Received: by 2002:aca:c287:: with SMTP id s129-v6mr7533236oif.3.1528710431689; Mon, 11 Jun 2018 02:47:11 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: From: Sebastian Gniazdowski Date: Mon, 11 Jun 2018 11:46:51 +0200 Message-ID: Subject: Re: Anyone familiar with auto-fu.zsh project? To: Eric Freese Cc: Zsh Users Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On 11 June 2018 at 10:25, Eric Freese wrote: > Wow this is much nicer. I've implemented on `develop` branch of > zsh-autosuggestions. Decided to do the testing, it's just checkout of develop branch and then normal everyday use. First impression was that suggestions appear very quickly, faster than with zpty. > Thank you! n/p, I use this in unpublished logger. Background process is started on demand with <( ), which happens when someone logs something with zflai-log. It stores to SQLite, MySQL, ElasticSearch, plain file. All works without any problems, and logging into <( ) spawned process has negligible duration, that's the point =E2=80=93 someone wants MySQL logs bu= t do not want slowdown. > Eric Freese > 303 875 2359 > > On Sun, Jun 10, 2018 at 11:24 PM, Sebastian Gniazdowski > wrote: >> >> 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 > >