From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.4 Received: (qmail 13876 invoked from network); 3 May 2023 10:02:49 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 3 May 2023 10:02:49 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1683108169; b=CyhcHoKitLUSTl/lunuw8iQ/OBMDAgxVWWtMDGE8VppCQDriTidshUfeCQhtAg3WyCBTiUgo8H CgHhRZPfcATOzQW6lYEUGamvINFq3fMkLgNTRu+Vk+BoliGaph0TJres6QrWkw4wwghoiX0EpQ URX6d/cHL4VGAsGd6Dcrl1gsJ+66HLEYuQec9FeqAfn6ui1gzdFprCwkFxl6hOqth5yg2yTL7K sOpnxhYfOMEuNCnJrYETFIIR3Z8iJc5w2n2Hc9KOcmywuFJuFa6USzNFsWo4K3mVl2GioUo+sz 9P+4Q9PPGEPgpYyGub5+c5cJxTNfl7U839K8mCBFDTWiXA==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-vs1-f54.google.com) smtp.remote-ip=209.85.217.54; dmarc=none header.from=axnet.nu; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1683108169; bh=sk6WqnoAKHAG5ERIMkQuFB271e1aafaJFtwvBztgxXU=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:To:Subject:Message-ID:Date:From:MIME-Version: DKIM-Signature; b=jTqoyvtfYxMKkKv8WFSNXuLrAxqcadsct2n1GudvSMfLYucH8cQnorlhTM52LaMxeCFh4PFajm PSzzkFqw/eJfkFzTvIlin7TjKog7Wxr/lbKx/Pcovpv2qaOTKkJFeBskiD7lVsTOOubGgdCWRS sNRdYXFPJk3yXwbn8JvlpjDc4K68jpoUbUOpHu2ShQf3Gm5LVQKIi6SSeJbOlPIbJaygyYdC1N VV5KEDcj+0jAsfSn3AzXN4yld8Tb1oYOP/x+P3LAQK+mea2Y+UIPAlTX3R8wY5KqA4O1Kls+V1 pXuAzkLDHhGtN8fW1D3mUiDBaC8x4qDyRWiu46FIPcYDgg==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:To:Subject:Message-ID: Date:From:MIME-Version:Reply-To:Cc:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References; bh=mpQmG7QDa/y3euHyCQgDB0PTVhIJadAsygkqRhW1AOs=; b=jLfVFoloTbz4Rxk+XE4y7Xfy4r v4gWW7Xu7bxHBXkfz33YfMAqqCznHJ5ab4bogdoQU/gIgfKoI0PFkeA8dsm5CZgz+AGXqRct2SgxW o90OzC45sMoEZCrp6BCMhNbXEjWZojrh57RARk0JsNspv+OW12lxoqfRWDwloOUtZ03XH8y1u0V1j MvWZFovQQ2wxpYK2rGL3LrUVvyUaNZZgyRy94Job1nF1ZtzfqbHYkEgey84WpSoqFp7MWHtSa1BYO Sj6HWdulbmFcOFQQyfeMVfOUEbgjFHdOOKyD8IdmeQC48e6jvyUC7pSTuBllMS37fN5eyR6Fc6LTg YsFA3Y6g==; Received: by zero.zsh.org with local id 1pu9Jx-0007Wx-Gn; Wed, 03 May 2023 10:02:49 +0000 Authentication-Results: zsh.org; iprev=pass (mail-vs1-f54.google.com) smtp.remote-ip=209.85.217.54; dmarc=none header.from=axnet.nu; arc=none Received: from mail-vs1-f54.google.com ([209.85.217.54]:59713) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1pu9Gd-00061p-9w; Wed, 03 May 2023 09:59:24 +0000 Received: by mail-vs1-f54.google.com with SMTP id ada2fe7eead31-42e35b7290fso1836930137.3; Wed, 03 May 2023 02:59:23 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683107962; x=1685699962; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=mpQmG7QDa/y3euHyCQgDB0PTVhIJadAsygkqRhW1AOs=; b=iI/Ey9FbAINkcZYst7jzkcoJ72CfoYCF1T7Ab6gLtALjH0434eSaP0zCrPlBwLTQCd d3mJyTZAh0UkrBX+E34VaoKFVsXMispKaGBo0Yo8WFYdcaZ2eZZ2RS0vLcWQ67lO45cY 5MvAFbn7EtzvtAhcg6j6esDU1DiA3ybOtKsnJSABCAwVcDH5wUbjHiXBnpUxFTmbJ+3e iDbxlyUvUy965tHg6Q20h79bDOKDGkMJ5O+o9ftK5GjPsGmrO+fsKmjDMcmBfu+kYAI6 QYwQARjySDUDVILjitDfT7DbuSnDOUCledgeeYqVIaOteDVgJVEnzWfD/5f/drVBjA5J G25A== X-Gm-Message-State: AC+VfDz5Cz4Ki3LFBQf0k9qH+5jMLE+cY9cJj/uuK+PNEH3YPN1FNYIk yRX3E1xzcxwAUhLv/mWBp5gg9WuRVzRozVemfKa+Y0X2hsw9Kw== X-Google-Smtp-Source: ACHHUZ5BYZheM9xIckRGtalATB/65rEIW+8Wv6C2ktR1yp1wUI3LJ6zklmT6l8qrxweEFyZH6vZ38s9CBro4fpSt8sI= X-Received: by 2002:a05:6102:259:b0:426:2a37:4a6b with SMTP id a25-20020a056102025900b004262a374a6bmr1039265vsq.25.1683107961961; Wed, 03 May 2023 02:59:21 -0700 (PDT) MIME-Version: 1.0 From: Fredrik Ax Date: Wed, 3 May 2023 11:59:10 +0200 Message-ID: Subject: completion ( compctl ) does not trigger for command names containing dashes To: zsh-users@zsh.org, zsh-workers@zsh.org Content-Type: multipart/alternative; boundary="0000000000003103ab05fac71ca7" X-Seq: 51701 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: , List-Subscribe: , List-Unsubscribe: , List-Post: List-Owner: List-Archive: --0000000000003103ab05fac71ca7 Content-Type: text/plain; charset="UTF-8" What I'm running: % cat /etc/debian_version 12.0 % dpkg -l zsh | grep ii ii zsh 5.9-4 amd64 shell with lots of features Hi, I've used zsh compctl since forever (late 90s or early 00s) but strangely never run into this before. I realized today when I intended to make some compctl config for update-alternatives that my completions where not triggered at all, it just used my standard fallback completion (files) ... so a very stripped down simple example to show the problem: This works fine: ~~~ zshprompt% compctl -k '(arg1 arg2 arg3)' nodash # typing 'nodash ' and hitting [Tab] once: zshprompt% nodash arg # hitting [Tab again] zshprompt% nodash arg arg1 arg2 arg3 ~~~ But this complete files instead: ~~~ # just showing the current dir for reference: zshprompt% ls . file2.txt myfile1.txt zshprompt% compctl -k '(arg1 arg2 arg3)' with-dash # typing 'with-dash ' and hitting [Tab] once: zshprompt% with-dash file2.txt myfile1.txt ~~~ As seen, my standard completion (listing current directory) is used rather than the one I added with compctl ... I also tried this with a totally clean zsh (no distribution or user configuration) and that shows the same problem, commands without dashes triggers completion, but commands with dashes, does not. I couldn't really find anything about this in the manpage (man zshcompctl) or online ... Is it a bug, or am I missing something? TIA, /frax --0000000000003103ab05fac71ca7 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

What I'= ;m running:

% cat /e= tc/debian_version
12.0

% dpkg -l zsh | grep ii =C2=A0
ii=C2=A0 zsh =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A05.9-4 =C2=A0 =C2=A0 =C2=A0 =C2=A0amd64 =C2=A0 =C2=A0 = =C2=A0 =C2=A0shell with lots of features

Hi,

I'= ve used zsh compctl since forever (late 90s or early 00s) but strangely nev= er run into this before. I realized today when I intended to make some compctl config for upda= te-alternatives that my completions where not triggered at all, it j= ust used my standard fallback completion (files) ... so a very stripped down simple example to show the problem:

This works fine:
~~~

zshprompt% <= span class=3D"gmail-hljs-built_in">compctl -k '(arg1 arg2 arg3)' nodash

#= typing 'nodash ' and hitting [Tab] once:
zshprompt% nodash arg

# hitting [Tab again]
zshprompt% nodash arg
arg1 arg2 arg3

~~~
But this complete files instead:
~~~


# just showing the current = dir for reference:
zshprompt% ls .
file2.txt myfile1.txt

zshprompt% compctl -k '= (arg1 arg2 arg3)' with-dash

# typing 'with-dash ' and hitting [Tab] once:

zshpr= ompt% with-dash
file2.txt myfile1.txt

~~~

As seen, my standard completion (listing current dire= ctory) is used rather than the one I added with compctl ... I also tried th= is with a totally clean zsh (no distribution or user configuration) and tha= t shows the same problem, commands without dashes triggers completion, but = commands with dashes, does not.

I couldn't really find = anything about this in the manpage (man zshcompctl) or online ...

Is it a bug, or am I = missing something?

TIA,

/frax


--0000000000003103ab05fac71ca7--