From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id +I6gKO54zGD3IgEAgWs5BA (envelope-from ) for ; Fri, 18 Jun 2021 12:43:58 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id wJBYJO54zGCXdAAAB5/wlQ (envelope-from ) for ; Fri, 18 Jun 2021 10:43:58 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 165C9B26D for ; Fri, 18 Jun 2021 12:43:58 +0200 (CEST) Received: from localhost ([::1]:53000 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1luByf-00009C-5k for larch@yhetil.org; Fri, 18 Jun 2021 06:43:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:32878) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1luBq2-0004dJ-MI for bug-guix@gnu.org; Fri, 18 Jun 2021 06:35:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:44335) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1luBq2-0006Jv-7e for bug-guix@gnu.org; Fri, 18 Jun 2021 06:35:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1luBq1-00067d-O9 for bug-guix@gnu.org; Fri, 18 Jun 2021 06:35:01 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#36868: [PATCH] etc: completion: remove package list when using completion on guix system build Resent-From: Solene Rapenne Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Fri, 18 Jun 2021 10:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 36868 X-GNU-PR-Package: guix X-GNU-PR-Keywords: easy To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 36868@debbugs.gnu.org Received: via spool by 36868-submit@debbugs.gnu.org id=B36868.162401245123469 (code B ref 36868); Fri, 18 Jun 2021 10:35:01 +0000 Received: (at 36868) by debbugs.gnu.org; 18 Jun 2021 10:34:11 +0000 Received: from localhost ([127.0.0.1]:55881 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1luBpC-00066S-Sz for submit@debbugs.gnu.org; Fri, 18 Jun 2021 06:34:11 -0400 Received: from perso.pw ([163.172.223.238]:3001) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1luBp9-00066J-IT for 36868@debbugs.gnu.org; Fri, 18 Jun 2021 06:34:10 -0400 Received: from perso.pw (localhost [127.0.0.1]) by perso.pw (OpenSMTPD) with ESMTP id acfb3494; Fri, 18 Jun 2021 12:33:59 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=perso.pw; h=date:from:to :cc:subject:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; s=1337; bh=fYDofMRJmBXj Mk3b6ifKfCFczMI=; b=ZCFXam2cWa6qQ574aJY8CAsLziCV1iOgQVMXBz/RaHm4 U83SybqnkX+qgZoqW++Op5xXZZ3W+V8KqnZA2GWeUbMSsyh+FG9FNt2+fTzdo0Mb UZFWqLBbouJXtFTXLMvM7E4g0oQDdtxMzdmmhGimMXtVBZmVn2WZp7GJzfxIDQU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=perso.pw; h=date:from:to:cc :subject:message-id:in-reply-to:references:mime-version :content-type:content-transfer-encoding; q=dns; s=1337; b=o0g/9I n9npeqvkqZzIuZA7XzPQF8US845WuTiyhwZa0QtPuTtHSrp3jsKHCRTYEK2pQTMK JNEFTF2WEFvxHFLIDdDAG3l9vNq7esTkOfNtrWuq9dnnd3AYno9FhrdLXcayNa8o AdV3Cj0OlY9uMKCcXtVTC3RmzKQVgoP51sOPo= Received: from localhost (176-154-164-34.abo.bbox.fr [176.154.164.34]) by perso.pw (OpenSMTPD) with ESMTPSA id f63c1778 (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO); Fri, 18 Jun 2021 12:33:55 +0200 (CEST) Date: Fri, 18 Jun 2021 12:33:53 +0200 Message-ID: <20210618123353.1782c21f@perso.pw> In-Reply-To: <875yybh4rq.fsf@gnu.org> References: <20190730204433.332b57c9@gmail.com> <20210615225815.2fd9ad77@perso.pw> <875yybh4rq.fsf@gnu.org> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" Reply-to: Solene Rapenne From: Solene Rapenne via Bug reports for GNU Guix X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1624013038; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=tRc/ISn5lFlFcmQdNRLYkc9LrIN2HxaoXM7fSTRt66U=; b=BIIhpUXB0rLTIgTasQInNBzctBCtlPrR3M1p7/fHQZoF0ElEjfxWLPrEOR7L2Kjd1qVmEb novB2Unxn7aEcpGc+kARR/hhjgYEltj5bEzwOTO6l9pS2s2eGwQAQLgGGjnDQZb5dGhDWx g63B6UAKpGejVfbIXhE+Qz8mjo02XkL5Y1+p/lfBR3kq7UmmMj2ycwE6OuRkETATk6Yz+m aFYWgeoh9+WfWudaKTpCpF0OesVM0XA0RLFUAmDlFszkLBK6zutyEcweOZzY6OiSZ4u3QG GNFTXtDJjBQ2r4rtGcMk9h0mlQ4MFruzmVgKLfgMYBfP3dfsPqsexR4dJMW+CA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1624013038; a=rsa-sha256; cv=none; b=dizufEgluYsAr3rPB7S9Wf34yBx0g19s9ThrQDfL36fA1EO3qS9oTwZhtAhz8teN1559ge SlZV70hTxbs9b3XAHRfYQXjeLbAWIexDhRV+1M0aO83OdFsHBuGKpiI93Zg+VNjIrgUzH1 /EuOHjGhH3EKIxsI1Q0iNd/O7lp/jjXHYR5EmPi8zX5p5DwLbJZMCp9Y2ZrOKaFdq15heu wP2b9H5GDjxe1MQdvIAR6e0NkXf02Gh3MPIg/jZpO6g5NneIEN5ZIfm/F8BmenfGc8Y9P5 o1TsGh+EAaFYxbIGrblngfjeuKIFgNW+JM9hbPCcnSfa2sJ3VGK/hUU8M9fndw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=perso.pw header.s=1337 header.b=ZCFXam2c; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Spam-Score: -2.93 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=perso.pw header.s=1337 header.b=ZCFXam2c; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Migadu-Queue-Id: 165C9B26D X-Spam-Score: -2.93 X-Migadu-Scanner: scn1.migadu.com X-TUID: Np7vK06mTums Le Fri, 18 Jun 2021 11:59:53 +0200, Ludovic Court=C3=A8s a =C3=A9crit : > Hi, >=20 > Solene Rapenne via Bug reports for GNU Guix skribis: >=20 > > --- > > etc/completion/bash/guix | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/etc/completion/bash/guix b/etc/completion/bash/guix > > index 26480e5863..ef98e9feca 100644 > > --- a/etc/completion/bash/guix > > +++ b/etc/completion/bash/guix > > @@ -235,7 +235,7 @@ _guix_complete () > > fi > > elif _guix_is_command "build" > > then > > - if _guix_is_dash_L || _guix_is_dash_m || _guix_is_dash= _f > > + if _guix_is_dash_L || _guix_is_dash_m || _guix_is_dash= _f || _guix_is_command "system" =20 >=20 > It seems to me that if _guix_is_command "build" is true, then > _guix_is_command "system" cannot also be true. WDYT? >=20 > Thanks for addressing this longstanding issue! >=20 > Ludo=E2=80=99. the file has been reworked in commits - dc3ba8c83602d69294e21d1b0c066f0d89890b56 - 80a17aae7991c6df061a98bb71734485f4ca17e2 now the code is entirely different and works as expected. IIRC when I worked on this piece of code, _guix_is_command "foobar" was looking for foobar in all words of the command. So you could have _guix_is_command returning true for "build" and "system" at the same time when using "guix system build".