From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: zsh-users-return-23686-ml=inbox.vuxu.org@zsh.org X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 6f8893bb for ; Fri, 28 Sep 2018 12:17:22 +0000 (UTC) Received: (qmail 12825 invoked by alias); 28 Sep 2018 12:17:05 -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: 23686 Received: (qmail 9033 invoked by uid 1010); 28 Sep 2018 12:17:05 -0000 X-Qmail-Scanner-Diagnostics: from mail-ua1-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.222.49):SA:0(-1.9/5.0):. Processed in 3.342096 secs); 28 Sep 2018 12:17:05 -0000 X-Envelope-From: pierpaolog@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:from:date:message-id:subject:to; bh=c4MmcpYcXBi+xgqEevfqla0+j4FggBLeexyDFQpRIIc=; b=Ikdt/AIZDRp3a9QJ6MNTkcwgJxgk1JIXg24u4GD/mAY6mK/vUgSqNdqL4du8ysCpkK 8+1VWGL8idmW47B/BE/ltT5me2JlHLj2yXu8xfeaVg0pn21QnWXH0NZ1nc0OigLJekbr 9y5IPrHF8Cvz35BLJ6lzqmrMqDsBMW1yOMbf5HuJVU18G7IaMXaoGqgnERUDhdyz/TYi Tc2mb0CQACPWtoD2IlpKifQsr2+rGc/aUjpQdmr0pwmsA6drcMCfBsrg5vjJ+r/+ul2S xISbSrkkEAbxIz80io3CjLK74UDphhgVgu85IaZpYWpkMEpcGW45U9T3JlWmy0hveJqY HmQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=c4MmcpYcXBi+xgqEevfqla0+j4FggBLeexyDFQpRIIc=; b=UvsNNsAQ+NKpApko0y7mhSkYyuWKgr70bk/znKyF0MRFh3kv3zxyQLHm42qL2rxTur Lnfn7DVsf+mvhAphLSKCCs45KuncWdwpMdk2eE2xIlRuUu+PiVykqtqcLBA5Eqz2+45n G9a3W+eQ/htTbBhG//ZbTDcS+eCV2Iq8jiPu6Qc+ZtNu6eYv4PkxHkwNBO09RLUqKSRk AxwTPDWkAcdJqyU9tLwBWRs6l+KlUBjkQABADYxqQMlZfKMb9u5jVv91TS4OMBL4ZgJI 9ZeGhwIgebpmp5XIzKxpDYm5aajW/s3MhCoNkOS7UTsZMbKB1pezgQJCtotosqKi+Gac Qpmg== X-Gm-Message-State: ABuFfohK2op+QIbwGcOdyAFMivq7B2KYoXN+D3BNOzxslr5dvClzMJM1 gtlRA+j3JYxa8e7iL1twx2hc8nBpDvCI86F+1glc+rxo X-Google-Smtp-Source: ACcGV63VY+zR0qL+EUxmVgBZG6axe1lJewYOlxXcjUDdl85BjPVyDKgzEkuZUTFOSk6wJ8TeM/Uj5MDCW/gnq+dnABU= X-Received: by 2002:ab0:6150:: with SMTP id w16-v6mr5995649uan.113.1538137018364; Fri, 28 Sep 2018 05:16:58 -0700 (PDT) MIME-Version: 1.0 From: Pier Paolo Grassi Date: Fri, 28 Sep 2018 14:16:22 +0200 Message-ID: Subject: space after completion To: Zsh-Users List Content-Type: multipart/alternative; boundary="00000000000098775f0576ed6eec" --00000000000098775f0576ed6eec Content-Type: text/plain; charset="UTF-8" Hello, I have noticed that when I define a completion function, which does something like: _arguments -s -S -A '-*' \ "*:commands:->commands" case $state in (commands) compadd -S '' -V commands -a -Q -U commands_array ;; esac (actual code stripped down a bit) the array commands_array is populated by some code with the "commands" I want to have completed. All works well, but when I choose a command the cursor stops right after the completion, instead of adding a space like _gnu_generic does when I complete the options. This way if I press tab again without inserting a space, the command I choose gets substituted with the first command from the completion menu and the menu is presented again. What would be a good way of achieving the same thing as _gnu_generic? is there some completion style that can be leveraged here? thanks in advance -- Pier Paolo Grassi email: pierpaolog@gmail.com linkedin: https://www.linkedin.com/in/pier-paolo-grassi-19300217 founder: https://www.meetup.com/it-IT/Machine-Learning-TO --00000000000098775f0576ed6eec--