Subject: bug#45295: “sudo guix system reconfigure” triggers re-clone/update of Git checkout

From: Ludovic Courtès <[email-masked]>
Date: Thu, 17 Dec 2020 15:01:43 +0100

Hi!

If you do, as a regular user:

  guix pull
  sudo guix system reconfigure …

the ‘guix system reconfigure’, as part of the downgrade-detection
machinery, triggers an update of the channel checkout(s) in
~root/.cache, even though ~USER/.cache is already up-to-date.

One way to avoid it might be to special-case the checkout cache
directory for when ‘SUDO_USER’ is set.

Thoughts?

Ludo’.