From debbugs-submit-bounces@debbugs.gnu.org Tue Apr 06 10:52:02 2021 Received: (at submit) by debbugs.gnu.org; 6 Apr 2021 14:52:02 +0000 Received: from localhost ([127.0.0.1]:41421 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lTn3c-0001Yt-Vs for submit@debbugs.gnu.org; Tue, 06 Apr 2021 10:52:02 -0400 Received: from lists.gnu.org ([209.51.188.17]:56572) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lTjkq-0008Gc-HR for submit@debbugs.gnu.org; Tue, 06 Apr 2021 07:20:24 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50196) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lTjkq-0005Hw-BZ for bug-guix@gnu.org; Tue, 06 Apr 2021 07:20:20 -0400 Received: from mout-p-201.mailbox.org ([2001:67c:2050::465:201]:63682) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1lTjki-0000Sl-Ks for bug-guix@gnu.org; Tue, 06 Apr 2021 07:20:20 -0400 Received: from smtp2.mailbox.org (smtp2.mailbox.org [80.241.60.241]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-201.mailbox.org (Postfix) with ESMTPS id 4FF4nK38tPzQjm2 for ; Tue, 6 Apr 2021 13:20:05 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=mailbox.org; h= content-type:content-type:mime-version:subject:subject :message-id:from:from:date:date:received; s=mail20150812; t= 1617708001; bh=RH0WoCgzkdKvF0sc+4uBMQzSQ7PswAA2dzAAES8G2/k=; b=w fSbE8lgrTVzpV6B8NzK5MiF9G82DVamwHMhD856IAND+ffBUI1eVxow8nALQzIjy DpwobWx0mbeJhgOnkJW1v9KSaTreGgC4GSYH8dCc2BzNIaGQRqCGsJNFzeB2iqr5 sERUcru2C254kQaSF9ime8p5yIHLc/Uq30nn8O+BexVSUrhosS4aFS4zNuuc6/JH tIOqX8ebmHuTFZThVkML7ejYqaK7YwOcAirg3w8Q19QlUcpBdoaTTGgXLpOy+1vr 8D2ukQuNjofthxx7o4/7EoALJv50XpdBpK8Hq99YjQhh/JNwFVn8SagA+YwVsIE5 JmJScJTxFn4cl89sz7oCQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailbox.org; s=mail20150812; t=1617708003; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=ZG+vlP7aonTroWZ/lW22M6UWG4ZqflXeT1EMUxmSdLY=; b=X3+R495AhVbL6Du7diLzZ++xuHjQvlVoNRACW8pLv8EH3kdb0DGrlwaiOurTw1pNpg9UoR 72wfPmtoJfKonbA4by9UJrp4rweBA17K0dF8TyrGqojbLnUrjJ5xFsdmWnnYAYy5dlejNQ 3lZoyNhatTxN5zj+RlA+mt6nK4G3Hxgdb0VVIg4pU9ROAN/g5Fah6/nvtUa+7dUiBU1Mjj 66HymMMeCs17ny9zp/clq8+jb3qY2Kv8/ujTHEcN0ZJLnoQEZenjedKehyAeDmKWM6T6Df ATaS+4LBZ6MOot2VSCfWf7iRZvKSlmVI0OHLY4BWt8LKx3V4YZwPd1f/5CVQZw== X-Virus-Scanned: amavisd-new at heinlein-support.de Received: from smtp2.mailbox.org ([80.241.60.241]) by gerste.heinlein-support.de (gerste.heinlein-support.de [91.198.250.173]) (amavisd-new, port 10030) with ESMTP id khzABxpZ6kB4 for ; Tue, 6 Apr 2021 13:20:01 +0200 (CEST) Date: Tue, 6 Apr 2021 13:20:01 +0200 (CEST) From: Brendan Tildesley To: "bug-guix@gnu.org" Message-ID: <704666652.34576.1617708001601@office.mailbox.org> Subject: "guix upgrade" and "guix package -u ." inconsistency MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_34575_1228745950.1617708001597" X-Priority: 3 Importance: Normal X-MBO-SPAM-Probability: X-Rspamd-Score: -4.31 / 15.00 / 15.00 X-Rspamd-Queue-Id: 6F9C41800 X-Rspamd-UID: d7a740 Received-SPF: pass client-ip=2001:67c:2050::465:201; envelope-from=btild@mailbox.org; helo=mout-p-201.mailbox.org X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Tue, 06 Apr 2021 10:51:55 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) ------=_Part_34575_1228745950.1617708001597 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Below, --do-not-upgrade appears to be behaving like "--only-upgrade". I rea= lised this comes about because I didn't use '=3D'. guix upgrade takes all other arguments to be upgrade regex's, but it still seems. _wrong_. Some long arguments in guix require and =3D sign after them, and the cli help indicat= es as much, but --do-not-upgrade seems to break that pattern and takes all argume= nts after it to be regexes's to match and not upgrade. flags that have this behaviour of acting on all arguments after them should indicate clearly the= y do that. and indicated if the '=3D' is optional using some intuitive notation. The line: --do-not-upgrade[=3DREGEXP] do not upgrade any packages matching REGEXP suggest it must take either no argument or only '=3Dsomething'. guix upgrade --help says that it is an alias for 'guix package -u .'. My understanding is that the meaning of alias is something that can be substit= uted and it will behave the same, like Bash aliases. We should change 'guix upgrade''s behaviour to be like 'guix package -u', taking all arguments aft= er --do-not-upgrade as regex's to not upgrade. b@jiu ~/code/guix [env]$ guix upgrade --do-not-upgrade '^[a-n]' The following packages will be upgraded: audacity (dependencies or package changed) cool-retro-term (dependencies or package changed) deluge (dependencies or package changed) diffoscope 170 =E2=86=92 171 emacs (dependencies or package changed) eog (dependencies or package changed) evince (dependencies or package changed) ffmpeg (dependencies or package changed) git 2.31.0 =E2=86=92 2.31.1 git:send-email 2.31.0 =E2=86=92 2.31.1 gnome-font-viewer (dependencies or package changed) gnome-tweaks (dependencies or package changed) godot (dependencies or package changed) ibus (dependencies or package changed) ibus-anthy (dependencies or package changed) icecat (dependencies or package changed) keepassxc (dependencies or package changed) lm-sensors (dependencies or package changed) lollypop (dependencies or package changed) mpv (dependencies or package changed) mumble (dependencies or package changed) 62.6 MB will be downloaded ^C b@jiu ~/code/guix [env]$ guix package -u . --do-not-upgrade '^[a-n]' The following packages will be upgraded: obs (dependencies or package changed) piper (dependencies or package changed) playonlinux (dependencies or package changed) rhythmbox (dependencies or package changed) stellarium (dependencies or package changed) syncthing-gtk (dependencies or package changed) tinc (dependencies or package changed) transmission:gui (dependencies or package changed) ungoogled-chromium (dependencies or package changed) vlc (dependencies or package changed) youtube-dl (dependencies or package changed) zrythm (dependencies or package changed) The following derivation will be built: /gnu/store/6ldzv7ilcsg4ah8vyig9vyh9y79yz6m1-tinc-1.1pre17.drv ------=_Part_34575_1228745950.1617708001597 MIME-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable =20 =20
Below, --do-not-upgrade appears to be behaving like "--only-upgrade". I = realised=20
this comes about because I didn't use '=3D'. guix upgrade takes all = other=20
arguments to be upgrade regex's, but it still seems. _wrong_.  = Some long=20
arguments in guix require and =3D sign after them, and the cli help = indicates as=20
much, but --do-not-upgrade seems to break that pattern and takes all= arguments=20
after it to be regexes's to match and not upgrade.  flags that = have this=20
behaviour of acting on all arguments after them should indicate clea= rly they do=20
that. and indicated if the '=3D' is optional using some intuitive no= tation.=20
The line:=20

   --do-not-upgrade[=3DREGEXP] do not upgrade any packages= matching REGEXP=20

suggest it must take either no argument or only '=3Dsomething'.=20

guix upgrade --help says that it is an alias for 'guix package -u .'= . My=20
understanding is that the meaning of alias is something that can be = substituted=20
and it will behave the same, like Bash aliases.  We should chan= ge 'guix=20
upgrade''s behaviour to be like 'guix package -u', taking all argume= nts after=20
--do-not-upgrade as regex's to not upgrade.=20


b@jiu ~/code/guix [env]$ guix upgrade --do-not-upgrade '^[a-n]'=20
The following packages will be upgraded:=20
   audacity        = ;  (dependencies or package changed)=20
   cool-retro-term   (dependencies or package ch= anged)=20
   deluge        &= nbsp;   (dependencies or package changed)=20
   diffoscope        17= 0 =E2=86=92 171=20
   emacs        &n= bsp;    (dependencies or package changed)=20
   eog        &nbs= p;      (dependencies or package changed)=20
   evince        &= nbsp;   (dependencies or package changed)=20
   ffmpeg        &= nbsp;   (dependencies or package changed)=20
   git        &nbs= p;      2.31.0 =E2=86=92 2.31.1=20
   git:send-email    2.31.0 =E2=86=92 2.31.= 1=20
   gnome-font-viewer (dependencies or package changed)=20
   gnome-tweaks      (dependencie= s or package changed)=20
   godot        &n= bsp;    (dependencies or package changed)=20
   ibus        &nb= sp;     (dependencies or package changed)=20
   ibus-anthy        (d= ependencies or package changed)=20
   icecat        &= nbsp;   (dependencies or package changed)=20
   keepassxc       &nbs= p; (dependencies or package changed)=20
   lm-sensors        (d= ependencies or package changed)=20
   lollypop        = ;  (dependencies or package changed)=20
   mpv        &nbs= p;      (dependencies or package changed)=20
   mumble        &= nbsp;   (dependencies or package changed)=20

62.6 MB will be downloaded=20
^C=20
b@jiu ~/code/guix [env]$ guix package -u . --do-not-upgrade '^[a-n]'= =20
The following packages will be upgraded:=20
   obs        &nbs= p;       (dependencies or package changed)=20
   piper        &n= bsp;     (dependencies or package changed)=20
   playonlinux        (= dependencies or package changed)=20
   rhythmbox       &nbs= p;  (dependencies or package changed)=20
   stellarium       &nb= sp; (dependencies or package changed)=20
   syncthing-gtk      (dependenci= es or package changed)=20
   tinc        &nb= sp;      (dependencies or package changed)=20
   transmission:gui   (dependencies or package c= hanged)=20
   ungoogled-chromium (dependencies or package changed)=20
   vlc        &nbs= p;       (dependencies or package changed)=20
   youtube-dl       &nb= sp; (dependencies or package changed)=20
   zrythm        &= nbsp;    (dependencies or package changed)=20

The following derivation will be built:=20
   /gnu/store/6ldzv7ilcsg4ah8vyig9vyh9y79yz6m1-tinc-1.1pre= 17.drv=20

------=_Part_34575_1228745950.1617708001597--