Message ID | 9184428ce5f7de56848b1c0018b2639dd0e8a5ca.camel@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | [bug#55317] doc: Clarify guix shell's DWIM behaviour. | expand |
Context | Check | Description |
---|---|---|
cbaines/comparison | success | View comparision |
cbaines/git branch | success | View Git branch |
cbaines/applying patch | success | View Laminar job |
cbaines/issue | success | View issue |
-------- Original Message -------- On May 8, 2022, 10:29 AM, Liliana Marie Prikler < liliana.prikler@gmail.com> wrote: --- Bonjour Guix, as can be seen from <http://logs.guix.gnu.org/guix/2022-05-08.log#164019>, the way in which guix shell interactively does what you mean is open to interpretation and different folks may mean different things when specifying nothing. Thank you Liliana, this is a helpful change!
Hi, Liliana Marie Prikler <liliana.prikler@gmail.com> skribis: > +++ b/doc/guix.texi > @@ -5693,17 +5693,16 @@ before @command{guix shell} was invoked. The next garbage collection > (@pxref{Invoking guix gc}) may clean up packages that were installed in > the environment and that are no longer used outside of it. > > -As an added convenience, when running from a directory that contains a > -@file{manifest.scm} or a @file{guix.scm} file (in this order), possibly > -in a parent directory, @command{guix shell} automatically loads the > -file---provided the directory is listed in > -@file{~/.config/guix/shell-authorized-directories}, and only for > -interactive use: > - > -@example > -guix shell > -@end example > - > +As an added convenience, @command{guix shell} when invoked interactively > +without any other arguments will try to do what you mean based on the > +files it locates in the current directory or parent directories. > +If it finds a @file{manifest.scm}, it uses this manifest as though > +it was given via @code{--manifest}. > +If it finds a @file{guix.scm}, it uses this package file as though > +it was given via @code{--development --file}. > +In either case, the file will only be loaded if the directory it > +resides in is listed in > +@file{~/.config/guix/shell-authorized-directories}. > This provides an easy way to define, share, and enter development > environments. It’s clearer like this, so go for it! Maybe you can keep the @example bit as that makes an easily visible anchor in the text. Thank you, Ludo’.
diff --git a/doc/guix.texi b/doc/guix.texi index 5399584cb0..249c5956e2 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -5693,17 +5693,16 @@ before @command{guix shell} was invoked. The next garbage collection (@pxref{Invoking guix gc}) may clean up packages that were installed in the environment and that are no longer used outside of it. -As an added convenience, when running from a directory that contains a -@file{manifest.scm} or a @file{guix.scm} file (in this order), possibly -in a parent directory, @command{guix shell} automatically loads the -file---provided the directory is listed in -@file{~/.config/guix/shell-authorized-directories}, and only for -interactive use: - -@example -guix shell -@end example - +As an added convenience, @command{guix shell} when invoked interactively +without any other arguments will try to do what you mean based on the +files it locates in the current directory or parent directories. +If it finds a @file{manifest.scm}, it uses this manifest as though +it was given via @code{--manifest}. +If it finds a @file{guix.scm}, it uses this package file as though +it was given via @code{--development --file}. +In either case, the file will only be loaded if the directory it +resides in is listed in +@file{~/.config/guix/shell-authorized-directories}. This provides an easy way to define, share, and enter development environments.