From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 12 09:24:44 2020 Received: (at submit) by debbugs.gnu.org; 12 Oct 2020 13:24:44 +0000 Received: from localhost ([127.0.0.1]:41951 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kRxoh-0008O6-KC for submit@debbugs.gnu.org; Mon, 12 Oct 2020 09:24:43 -0400 Received: from lists.gnu.org ([209.51.188.17]:49570) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kRxod-0008Nu-Pm for submit@debbugs.gnu.org; Mon, 12 Oct 2020 09:24:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45930) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kRxod-0001f7-Ii for guix-patches@gnu.org; Mon, 12 Oct 2020 09:24:39 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:42652) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kRxoc-0005ln-ED; Mon, 12 Oct 2020 09:24:38 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=54748 helo=gnu.org) by fencepost.gnu.org with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kRxob-0005Vw-Rm; Mon, 12 Oct 2020 09:24:38 -0400 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= To: guix-patches@gnu.org Subject: [PATCH] guix build: Move package transformation options behind '--help-transform'. Date: Mon, 12 Oct 2020 15:24:31 +0200 Message-Id: <20201012132431.21240-1-ludo@gnu.org> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit Cc: =?UTF-8?q?Ludovic=20Court=C3=A8s?= 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: -3.3 (---) This change declutters the '--help' output. * guix/scripts/build.scm (show-build-options-help) (%standard-build-options): Add '--help-transform'. (show-transformation-options-help): Make private. (show-help): Remove call to 'show-transformation-options-help'. * guix/scripts/build.scm (show-help): Likewise. * guix/scripts/environment.scm (show-help): Likewise. * guix/scripts/graph.scm (show-help): Likewise. * guix/scripts/install.scm (show-help): Likewise. * guix/scripts/pack.scm (show-help): Likewise. * guix/scripts/package.scm (show-help): Likewise. * guix/scripts/upgrade.scm (show-help): Likewise. * doc/guix.texi (Package Transformation Options): Mention '--help-transform'. --- doc/guix.texi | 5 +++++ guix/scripts/build.scm | 14 ++++++++++---- guix/scripts/environment.scm | 2 -- guix/scripts/graph.scm | 5 +---- guix/scripts/install.scm | 2 -- guix/scripts/pack.scm | 2 -- guix/scripts/package.scm | 2 -- guix/scripts/upgrade.scm | 2 -- 8 files changed, 16 insertions(+), 18 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 1885690c81..8044073bea 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -9257,6 +9257,11 @@ Package transformation options are preserved across upgrades: @command{guix upgrade} attempts to apply transformation options initially used when creating the profile to the upgraded packages. +The available options are listed below. Most commands support them and +also support a @option{--help-transform} option that lists all the +available options and a synopsis (these options are not shown in the +@option{--help} output for brevity). + @table @code @item --with-source=@var{source} diff --git a/guix/scripts/build.scm b/guix/scripts/build.scm index 6ca669d172..f4a8af035b 100644 --- a/guix/scripts/build.scm +++ b/guix/scripts/build.scm @@ -65,7 +65,6 @@ %transformation-options options->transformation manifest-entry-with-transformations - show-transformation-options-help guix-build register-root @@ -717,6 +716,8 @@ options handled by 'set-build-options-from-command-line', and listed in -c, --cores=N allow the use of up to N CPU cores for the build")) (display (G_ " -M, --max-jobs=N allow at most N build jobs")) + (display (G_ " + --help-transform list package transformation options not shown here")) (display (G_ " --debug=LEVEL produce debugging output at LEVEL"))) @@ -853,7 +854,14 @@ use '--no-offload' instead~%"))) (if c (apply values (alist-cons 'max-jobs c result) rest) (leave (G_ "not a number: '~a' option argument: ~a~%") - name arg))))))) + name arg))))) + (option '("help-transform") #f #f + (lambda _ + (format #t + (G_ "Available package transformation options:~%")) + (show-transformation-options-help) + (newline) + (exit 0))))) ;;; @@ -910,8 +918,6 @@ Build the given PACKAGE-OR-DERIVATION and return their output paths.\n")) (newline) (show-build-options-help) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm index 085f11a9d4..91ce2af9bb 100644 --- a/guix/scripts/environment.scm +++ b/guix/scripts/environment.scm @@ -179,8 +179,6 @@ COMMAND or an interactive shell in that environment.\n")) (newline) (show-build-options-help) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " diff --git a/guix/scripts/graph.scm b/guix/scripts/graph.scm index d7a08a4fe1..0d11fc9795 100644 --- a/guix/scripts/graph.scm +++ b/guix/scripts/graph.scm @@ -35,8 +35,7 @@ #:use-module ((guix diagnostics) #:select (location-file formatted-message)) #:use-module ((guix scripts build) - #:select (show-transformation-options-help - options->transformation + #:select (options->transformation %standard-build-options %transformation-options)) #:use-module (srfi srfi-1) @@ -546,8 +545,6 @@ Emit a representation of the dependency graph of PACKAGE...\n")) (display (G_ " -L, --load-path=DIR prepend DIR to the package module search path")) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " diff --git a/guix/scripts/install.scm b/guix/scripts/install.scm index 894e60f9da..5aafe3bd6d 100644 --- a/guix/scripts/install.scm +++ b/guix/scripts/install.scm @@ -38,8 +38,6 @@ This is an alias for 'guix package -i'.\n")) (newline) (show-build-options-help) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " diff --git a/guix/scripts/pack.scm b/guix/scripts/pack.scm index 0b66da01f9..a5a70d5162 100644 --- a/guix/scripts/pack.scm +++ b/guix/scripts/pack.scm @@ -1043,8 +1043,6 @@ last resort for relocation." Create a bundle of PACKAGE.\n")) (show-build-options-help) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -f, --format=FORMAT build a pack in the given FORMAT")) (display (G_ " diff --git a/guix/scripts/package.scm b/guix/scripts/package.scm index 2f04652634..ba62d98682 100644 --- a/guix/scripts/package.scm +++ b/guix/scripts/package.scm @@ -397,8 +397,6 @@ Install, remove, or upgrade packages in a single transaction.\n")) (newline) (show-build-options-help) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " diff --git a/guix/scripts/upgrade.scm b/guix/scripts/upgrade.scm index 8c7abd133a..dee7445994 100644 --- a/guix/scripts/upgrade.scm +++ b/guix/scripts/upgrade.scm @@ -39,8 +39,6 @@ This is an alias for 'guix package -u'.\n")) (newline) (show-build-options-help) (newline) - (show-transformation-options-help) - (newline) (display (G_ " -h, --help display this help and exit")) (display (G_ " -- 2.28.0 From debbugs-submit-bounces@debbugs.gnu.org Mon Oct 19 07:54:38 2020 Received: (at 43953) by debbugs.gnu.org; 19 Oct 2020 11:54:38 +0000 Received: from localhost ([127.0.0.1]:40187 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUTkI-0002rp-TD for submit@debbugs.gnu.org; Mon, 19 Oct 2020 07:54:38 -0400 Received: from mail-wr1-f65.google.com ([209.85.221.65]:42881) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUTkG-0002rZ-EN for 43953@debbugs.gnu.org; Mon, 19 Oct 2020 07:54:33 -0400 Received: by mail-wr1-f65.google.com with SMTP id j7so6980865wrt.9 for <43953@debbugs.gnu.org>; Mon, 19 Oct 2020 04:54:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=4Keqk6lgvGQAdNioTAwnB3/OwWG84a71DB518Gz3TdU=; b=EsP+nHPUme1mT5lmoXJw0bMbzLG2c5Q/O/s9ASH+zbhE8Bvz144Qol36kW4LWi8bHk 3mrhbPNrQurMtgF9+RYYCZEo2xDW/HkJSSMY+G3jGPtHY6UqC6NIg8Z3lEMGbXEdk+Oe 6jdohPMIKXwlMseo8H9kZEd84nTDhSXTt3o2JF1VxiX7+tppmfkjYrPMFvxJitimElPI ipy3CglMgLyTSMj3WC4OUVliDcFmnRsDBCJqvF9ybtdObMfD6gftidVdKFjjbGm4tvO0 zegX7FEWhJ4RMA/nnQWjfYtO9B/cjBxNC07xuWETIhc8u8WDE1NGv+8mwF2ZT1txsqY5 Vjqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=4Keqk6lgvGQAdNioTAwnB3/OwWG84a71DB518Gz3TdU=; b=FHSSycBAAO+kWds8+jy42Qjh8E2Espq5qdqYxU8PkgCpZpV3bcuXki31qKpfiFZnqS EIFQ8lfv9DbydaFvDGNXgvLadzdZTjnoS+k3zPn8CMshNVP7PklFQM++b2CwcxQdjwFU nWIYWLXA/Jr6ohjecmlFwJCqi9/bNEMVI4x5n+L4s0Q/9+kb9Ye4rUjCB/wDDyIFv+rj hok9Qezx/MhxyeTYviodYi3TXCIc4l5D8oawu1to1Q+CmKZorlmzzXuYSGINKkMMaECB ibALPLUCSJ8myw970diEsFKT6T2sE2i9+24LWW5cskJ+gyCl7hA9neTI7hSlB/oeKP7t j5rw== X-Gm-Message-State: AOAM533xdJgKOw2ukX4g5JwgwZ73qLn40YjisB4g5N9aZnUceOIMhMhg JumR1kO5JoyVTZF4btwrlpmRt+p451m4Uw== X-Google-Smtp-Source: ABdhPJxA8EWXiNhU7M9r7Ilsg3i3J7XleydKy5s3yz3LU5JvRqVXyO5NJFSEn37VhGs1bOHEVnmrJw== X-Received: by 2002:a5d:6ac6:: with SMTP id u6mr19228507wrw.65.1603108466312; Mon, 19 Oct 2020 04:54:26 -0700 (PDT) Received: from unfall (218.139.134.37.dynamic.jazztel.es. [37.134.139.218]) by smtp.gmail.com with ESMTPSA id s11sm18020861wrm.56.2020.10.19.04.54.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Oct 2020 04:54:25 -0700 (PDT) From: =?utf-8?Q?Miguel_=C3=81ngel_Arruga_Vivas?= To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: [bug#43953] [PATCH] guix build: Move package transformation options behind '--help-transform'. References: <20201012132431.21240-1-ludo@gnu.org> Date: Mon, 19 Oct 2020 13:53:28 +0200 In-Reply-To: <20201012132431.21240-1-ludo@gnu.org> ("Ludovic =?utf-8?Q?Cou?= =?utf-8?Q?rt=C3=A8s=22's?= message of "Mon, 12 Oct 2020 15:24:31 +0200") Message-ID: <874kmqph3b.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.2 (/) X-Debbugs-Envelope-To: 43953 Cc: 43953@debbugs.gnu.org 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: -0.7 (/) Hi, I did a quick test with this, and it LGTM. I'd only suggest to clarify what should be the commit title for these changes, as both "guix build:" and "build:" are used. Happy hacking! Miguel From debbugs-submit-bounces@debbugs.gnu.org Tue Oct 20 10:38:53 2020 Received: (at 43953-done) by debbugs.gnu.org; 20 Oct 2020 14:38:53 +0000 Received: from localhost ([127.0.0.1]:46276 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUsmq-0001Lf-Sj for submit@debbugs.gnu.org; Tue, 20 Oct 2020 10:38:53 -0400 Received: from eggs.gnu.org ([209.51.188.92]:39090) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUsmo-0001LM-Tl for 43953-done@debbugs.gnu.org; Tue, 20 Oct 2020 10:38:51 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:56601) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kUsmi-0001dB-O9; Tue, 20 Oct 2020 10:38:45 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=46098 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kUsmi-0006pd-Bp; Tue, 20 Oct 2020 10:38:44 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: 43953-done@debbugs.gnu.org Subject: Re: [bug#43953] [PATCH] guix build: Move package transformation options behind '--help-transform'. References: <20201012132431.21240-1-ludo@gnu.org> Date: Tue, 20 Oct 2020 16:38:43 +0200 In-Reply-To: <20201012132431.21240-1-ludo@gnu.org> ("Ludovic =?utf-8?Q?Cou?= =?utf-8?Q?rt=C3=A8s=22's?= message of "Mon, 12 Oct 2020 15:24:31 +0200") Message-ID: <87zh4hc68c.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 43953-done Cc: Miguel =?utf-8?Q?=C3=81ngel?= Arruga Vivas 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: -3.3 (---) Hi! Ludovic Court=C3=A8s skribis: > This change declutters the '--help' output. > > * guix/scripts/build.scm (show-build-options-help) > (%standard-build-options): Add '--help-transform'. > (show-transformation-options-help): Make private. > (show-help): Remove call to 'show-transformation-options-help'. > * guix/scripts/build.scm (show-help): Likewise. > * guix/scripts/environment.scm (show-help): Likewise. > * guix/scripts/graph.scm (show-help): Likewise. > * guix/scripts/install.scm (show-help): Likewise. > * guix/scripts/pack.scm (show-help): Likewise. > * guix/scripts/package.scm (show-help): Likewise. > * guix/scripts/upgrade.scm (show-help): Likewise. > * doc/guix.texi (Package Transformation Options): Mention '--help-transfo= rm'. Pushed as 6701f64f7329cdbeda70bcaf38523c9098e5a938. Miguel =C3=81ngel Arruga Vivas skribis: > I'd only suggest to clarify what should be the commit title for these > changes, as both "guix build:" and "build:" are used. =E2=80=9Cbuild:=E2=80=9D is used for changes to the build system: Makefiles, configure.ac, etc. =E2=80=9Cguix build:=E2=80=9D is used for changes to (guix scripts build). At least that=E2=80=99s my intention. :-) Thanks, Ludo=E2=80=99. From unknown Fri Sep 19 09:04:05 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 18 Nov 2020 12:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator