From 2884abb3df4f95cef75219435ce9c1c968068568 Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer <maxim.cournoyer@gmail.com> Date: Fri, 11 Aug 2023 17:09:08 -0400 Subject: refresh: Add --target-version option. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * guix/scripts/refresh.scm (%options): Register 'target-version' long version. (update-specification->update-spec): Add a fallback-version argument. (options->update-specs): Honor target-version option. * tests/guix-refresh.sh: Test it. * doc/guix.texi (Invoking guix refresh): Document it. Reviewed-by: Ludovic Courtès <ludo@gnu.org> --- doc/guix.texi | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 8469d09245..b50feed4c4 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -14529,6 +14529,26 @@ gnu/packages/guile.scm:147:2: guile: updating from version 2.0.10 to version 2.0 @dots{} @end example +In some specific cases, you may have many packages specified via a +manifest or a module selection which should all be updated together; for +these cases, the @option{--target-version} option can be provided to have +them all refreshed to the same version, as shown in the examples below: + +@example +$ guix refresh qtbase qtdeclarative --target-version=6.5.2 +gnu/packages/qt.scm:1248:13: qtdeclarative would be upgraded from 6.3.2 to 6.5.2 +gnu/packages/qt.scm:584:2: qtbase would be upgraded from 6.3.2 to 6.5.2 +@end example + +@example +$ guix refresh --manifest=qt5-manifest.scm --target-version=5.15.10 +gnu/packages/qt.scm:1173:13: qtxmlpatterns would be upgraded from 5.15.8 to 5.15.10 +gnu/packages/qt.scm:1202:13: qtdeclarative would be upgraded from 5.15.8 to 5.15.10 +gnu/packages/qt.scm:1762:13: qtserialbus would be upgraded from 5.15.8 to 5.15.10 +gnu/packages/qt.scm:2070:13: qtquickcontrols2 would be upgraded from 5.15.8 to 5.15.10 +@dots{} +@end example + Sometimes the upstream name differs from the package name used in Guix, and @command{guix refresh} needs a little help. Most updaters honor the @code{upstream-name} property in package definitions, which can be used -- cgit v1.2.3