On Thu, Jan 16, 2025 at 11:46:45PM +0100, David Lecompte wrote:
> Sorry, my mistake, I actually ran "guix pull" and "sudo guix system
> reconfigure /etc/config.scm".
[...]
> When I first read
> https://guix.gnu.org/manual/devel/en/html_node/After-System-Installation.html,
> I thought it was the way to update guix system, even though I found it
> strange to see that "guix pull" was done without "sudo", while it was used
> for "guix system reconfigure /etc/config.scm".

Interesting! Previously, the Guix docs would not have recommended doing
it like that. The environment you get when you run `sudo` without any
options was considered to be somewhat ambiguous and not useful for Guix.

There's no reason it should work for the topic at hand, as I understand
it, but I just tried it and it did work in the way you meant it to: it
preserved the relevant portions of the environment.

However, it obviously isn't working for you, so forget about it.

> Based on your explanations, if I run "guix pull" (as david) and then "sudo -
> E guix system reconfigure /etc/config.scm", I can update the system fine, is
> that right?

Yes. You can test it by doing `sudo -E guix show linux-libre` and
checking if it shows the kernel versions you expect.

> If so, is there a need to run "sudo -i guix pull" ever at all?

If you want your root user to have an up to date copy of Guix, then you
should do it. Remember that, in Guix, package management is per-user.

> One thing that I wonder about now, I believe I never ran "guix pull" with
> sudo, but upon installation, linux-libre was a 6.0 something version, and
> after the reconfigure with sudo, the version has become 6.11. How could that
> happen?

Like I said above, *something* is funny. But you can avoid that by being
explicit when you elevate your privileges.

> Besides, I use guix on trisquel and parabola as well and I contributed to
> the trisquel wiki page to use guix, 
> https://trisquel.info/en/wiki/gnu-guix-package-manager. This came from
> reading the guix manual and one advice received from this list once, I hope
> we got it right. Personally, I am a little puzzled that "sudo -i guix pull"
> alone and restart of the guix daemon are the only things to do with sudo.

You can do as much or as little as you want with sudo.

Reply via email to