Message ID | 1b75951ffc583006980d809718e5cdc4fd1c3d37.1615911469.git.public@yoctocell.xyz |
---|---|
State | Accepted |
Headers | show |
Series | [bug#47163] doc: Add snippet for running 'guix refresh' on installed packages | expand |
Context | Check | Description |
---|---|---|
cbaines/submitting builds | success | |
cbaines/comparison | success | View comparision |
cbaines/git branch | success | View Git branch |
cbaines/applying patch | success | View Laminar job |
cbaines/issue | success | View issue |
Hi, Xinglu Chen <public@yoctocell.xyz> skribis: > * doc/guix.texi (Invoking guix refresh): Add snippet that runs 'guix refresh' > on all the packages installed in the current profile. [...] > +You can also quickly update all the packages installed in the current > +profile with the following snippet: > + > +@example > +$ guix refresh -u $(guix package --list-installed | cut -f1) > +@end example > + > +This is handy if you don't use manifests for installing packages into > +your profile. Note that if you type this literally, it fails along these lines: --8<---------------cut here---------------start------------->8--- $ guix refresh -u grep Starting download of /tmp/guix-file.yLXS45 From https://ftpmirror.gnu.org/gnu/grep/grep-3.6.tar.xz... following redirection to `https://gnu.mirror.constant.com/grep/grep-3.6.tar.xz'... …6.tar.xz 1.5MiB 2.3MiB/s 00:01 [##################] 100.0% Starting download of /tmp/guix-file.NgvvW4 From https://ftpmirror.gnu.org/gnu/grep/grep-3.6.tar.xz.sig... following redirection to `https://mirrors.ocf.berkeley.edu/gnu/grep/grep-3.6.tar.xz.sig'... …tar.xz.sig 833B 1.8MiB/s 00:00 [##################] 100.0% gpgv: Signature made Mon 09 Nov 2020 05:40:03 AM CET gpgv: using RSA key 155D3FC500C834486D1EEA677FD9FCCB000BEEEE gpgv: Good signature from "Jim Meyering <jim@meyering.net>" gpgv: aka "Jim Meyering <meyering@fb.com>" gpgv: aka "Jim Meyering <meyering@gnu.org>" gnu/packages/base.scm:99:12: grep: updating from version 3.4 to version 3.6... guix refresh: error: mkstemp!: Read-only file system --8<---------------cut here---------------end--------------->8--- So I think this example may be misleading. We could instead suggest ./pre-inst-env, with a link to “Running Guix Before It Is Installed”, and possibly mention the ‘--with-latest’ option as well. WDYT? Thanks, Ludo’.
On Tue, Mar 16 2021, Ludovic Courtès wrote: >> * doc/guix.texi (Invoking guix refresh): Add snippet that runs 'guix refresh' >> on all the packages installed in the current profile. > > [...] > >> +You can also quickly update all the packages installed in the current >> +profile with the following snippet: >> + >> +@example >> +$ guix refresh -u $(guix package --list-installed | cut -f1) >> +@end example >> + >> +This is handy if you don't use manifests for installing packages into >> +your profile. > > Note that if you type this literally, it fails along these lines: > > --8<---------------cut here---------------start------------->8--- > $ guix refresh -u grep > > Starting download of /tmp/guix-file.yLXS45 > From https://ftpmirror.gnu.org/gnu/grep/grep-3.6.tar.xz... > following redirection to `https://gnu.mirror.constant.com/grep/grep-3.6.tar.xz'... > …6.tar.xz 1.5MiB 2.3MiB/s 00:01 [##################] 100.0% > > Starting download of /tmp/guix-file.NgvvW4 > From https://ftpmirror.gnu.org/gnu/grep/grep-3.6.tar.xz.sig... > following redirection to `https://mirrors.ocf.berkeley.edu/gnu/grep/grep-3.6.tar.xz.sig'... > …tar.xz.sig 833B 1.8MiB/s 00:00 [##################] 100.0% > gpgv: Signature made Mon 09 Nov 2020 05:40:03 AM CET > gpgv: using RSA key 155D3FC500C834486D1EEA677FD9FCCB000BEEEE > gpgv: Good signature from "Jim Meyering <jim@meyering.net>" > gpgv: aka "Jim Meyering <meyering@fb.com>" > gpgv: aka "Jim Meyering <meyering@gnu.org>" > gnu/packages/base.scm:99:12: grep: updating from version 3.4 to version 3.6... > guix refresh: error: mkstemp!: Read-only file system > --8<---------------cut here---------------end--------------->8--- > > So I think this example may be misleading. We could instead suggest > ./pre-inst-env, with a link to “Running Guix Before It Is Installed”, > and possibly mention the ‘--with-latest’ option as well. > > WDYT? Sorry, I should have tested the command... When you say "--with-latest", do you mean `guix package -i grep --with-latest`?
Xinglu Chen <public@yoctocell.xyz> skribis: > On Tue, Mar 16 2021, Ludovic Courtès wrote: [...] >> So I think this example may be misleading. We could instead suggest >> ./pre-inst-env, with a link to “Running Guix Before It Is Installed”, >> and possibly mention the ‘--with-latest’ option as well. >> >> WDYT? > > Sorry, I should have tested the command... When you say "--with-latest", > do you mean `guix package -i grep --with-latest`? Yes, see the “Package Transformation Options” section of the manual. Ludo’.
diff --git a/doc/guix.texi b/doc/guix.texi index 3e7ffc81bc..752dce9072 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -11722,6 +11722,16 @@ @code{idutils} packages. The @option{--select} option would have no effect in this case. +You can also quickly update all the packages installed in the current +profile with the following snippet: + +@example +$ guix refresh -u $(guix package --list-installed | cut -f1) +@end example + +This is handy if you don't use manifests for installing packages into +your profile. + When considering whether to upgrade a package, it is sometimes convenient to know which packages would be affected by the upgrade and should be checked for compatibility. For this the following option may