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.5 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A,RCVD_IN_DNSWL_MED, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 31182 invoked from network); 15 Jul 2023 16:52:09 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 15 Jul 2023 16:52:09 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1689439929; b=aZD5l4wWcYSFnZys+9+qIjAraqJHyPtncN04g8NYvW7TzKgpofIjajoNqluLxK5wVn2S680IpX FIehvsk/B92Fv5haFRoDPlWELImOsMa2EfIXc5yJiiXj/5gogjbpKz0WMSqildfd2LTPMWLTTT myM3ymfNDIIHqaHhgfedxPJ3Ky0eIxICmLuakhzSZiAqz2sQza0fRDLpsvU07UsdMAmYitPsOe AyZAnpUOZT+nGG5okDCkAAltv1kffj6Hbph9Ne2+KiGIGa6ypYoNaQU9wraBd6ZgptY7Eg10u3 h2baa+3Owij/nEq3vvMUrOZpebyUuWmtRBYlUWLxG7gGeg==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (redisdead.crans.org) smtp.remote-ip=185.230.79.39; dkim=pass header.d=crans.org header.s=mail header.a=rsa-sha256; dmarc=none header.from=crans.org; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1689439929; bh=tRiD30BP5R9ld0sduesV/vH5c52ufwbYz/ba9c9LMeE=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:In-Reply-To:From: References:Cc:To:Subject:MIME-Version:Date:Message-ID:DKIM-Signature: DKIM-Signature; b=Lo6VSOR2KcP0szT9kG9eJuLjbi4NI6rWkP/B51KMc9rNHsxo2lbGY7uh05orlGLrGhuorxLfnI 96e3iH3zo1Yhlfq3RlvqDW9w64U17aiecvi0n/oIiHK8pDTJKxNJJRl0eNAQzlobf79aBJj84/ PCNZ4dE4wiip9SGSTV6ALCIRBSgnRz1IrNStShXI0b/1GtueKZqFgxkhTRK/aseabpK9VWBtD6 mJZWar7OsuoXWp/INb075i0Ts8dx0c6Q/MBG5yHpBKAsXJ1KOza17/rpcpmvxCdqLBV5VQ6Ovk G2d38VEDiFIj8Dkf0YlHZUOE/OsPHtnmx9XpbNUGO4aH5Q==; 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-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=zXrprb1pZk2/9qhV5gleTjUZtTN2RAadFq+HvJQWGFM=; b=ljMkUuIalxEw8vXsqd5QKf++ZU 78mhr3aw/QifdJ4cC45iiMr3gq6Fd8fb2iU2PDbKGS9FhJ9Q84BEAJwnD3h9RU/P0bqszz8Y2hMke 6cm++ucg9Am9LZtxAUmB6HmQ9mZg9d6ONN/NV24DAoaWlqa/T1WtNnu4G4VL1mBZYxj/06V4qv0Rr YmN1QuoMFMihIXQEF5LgiozdsbZHPDS+SbO3eilL9l8YyHURvh++/8GPLLS6k/cBhY6FftPCc7OfR JbYjpK452EPYHyIcY9wc5coWkQzVeDvX5oMB7rGG/xv8Vly8u8NMbj+0ciDBZ97ZKJUcsX3gCimhj SN+xfy/g==; Received: by zero.zsh.org with local id 1qKiV7-000HX8-1M; Sat, 15 Jul 2023 16:52:09 +0000 Authentication-Results: zsh.org; iprev=pass (redisdead.crans.org) smtp.remote-ip=185.230.79.39; dkim=pass header.d=crans.org header.s=mail header.a=rsa-sha256; dmarc=none header.from=crans.org; arc=none Received: from redisdead.crans.org ([185.230.79.39]:58508) (DNSSEC AD) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1qKiUS-000HDb-Py; Sat, 15 Jul 2023 16:51:35 +0000 Received: from [IPV6:2a01:e0a:1aa:1110:df14:db17:ddf4:496d] (unknown [IPv6:2a01:e0a:1aa:1110:df14:db17:ddf4:496d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by redisdead.crans.org (Postfix) with ESMTPSA id 18551238; Sat, 15 Jul 2023 18:51:28 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=crans.org; s=mail; t=1689439888; bh=tRiD30BP5R9ld0sduesV/vH5c52ufwbYz/ba9c9LMeE=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=Cf06HNbXF/Rp/4Fngmua0HpLtZy5qPixdL1Y7cwrJ082hT/TANvZNJKXkrPEUDHPU tuaDzjd2LC3BAh5LE3dvyFIxcEVR9MV97XoTlJm77HDZO6qn6oilWI9GbsqkwZWG5f RFX9MBc4MGeutmkqjzfdW/vZ81ZCvwv6o7SV84MzsPscU6EVaFglt/lifM03X2FQcN Nc/nfXWbG81TN0Eaaow1HA/UNMrIBSyJYkT4YmCvO0VCTB7g9nRzMsYzErC4qU5Km8 8RCx1sxuJnrcZ6HPNfxUWQMGw2rhlOntEovCNicneBk0i2fCiGpadOp0YG/2ke8/jz os6f5o+CcYO+C/AGHcTUodgGhR2ySdMGbcPh+JDUP/+1jtJfks76jzU6PIbYHXXG+T 6bw4yWG1IYIB/THNkCuWXWCipN8Ox/4k0M4viwOz+X11Fis3g15smj8JpSSYPNwJzQ +djpM2f+VZuYO34ClGrGtTysb/vfhPuUTYohOBPFsKm0Q2Bm0vUz9c7AC1/E8ioFm6 PriKVz3MomO2eZF1ehI6nUwx+hNChMzDQcb8IBtXUY0s96EO4H+pB0uUOuiWWjyYtZ eU8WCh+Ugakef0BNaYlOZ4xthWwdXU0iKd10whRSWOWvsylw4jY/koJ+kRIzDUQUWk qhTReytssMJK2cCCAMrH7tJc= Message-ID: <30192b9e-b6a8-e19f-efb5-5af0fb710951@crans.org> Date: Sat, 15 Jul 2023 18:51:27 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: _files -g offers files that don't match the pattern and conversely Content-Language: en-US, en-AU, fr To: Bart Schaefer Cc: zsh-workers@zsh.org References: From: Johan Grande In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Seq: 51939 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: Le 15/07/2023 à 18:16, Bart Schaefer a écrit : > On Sat, Jul 15, 2023 at 6:32 AM Johan Grande wrote: >> >> % _f() { _files -g 'c(.)' }; compdef _f f >> % f >> a b # even though 'a' and 'b' don't match the pattern > > The only way I can make this happen is if "a" and "b" are directories. > _files will complete local directory names if there are no matching > files. In my test they are regular files, but the problem disappears if I replace /usr/share/zsh/functions/Completion/ with that of zsh 5.9, so it seems that this one was fixed. >> [...] >> % _f() { _files -g 'c' }; compdef _f f >> % f # becomes >> % f c # even though there is no such file > > There's only one possible completion, so it's offered. > OK, thank you. -- Johan