unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: David Boilleau via Guix-patches via <guix-patches@gnu.org>
To: 74258@debbugs.gnu.org
Cc: David Boilleau <david_boilleau@gmx.fr>
Subject: [bug#74258] [PATCH 2/3] guix-install.sh: Replace `ROOT_HOME` with `~root`
Date: Fri,  8 Nov 2024 15:10:23 +0100	[thread overview]
Message-ID: <1a9aa88fcacc1c9b2f173a0aa8a6aa7327a3a2b7.1731055803.git.david_boilleau@gmx.fr> (raw)
In-Reply-To: <cover.1731055803.git.david_boilleau@gmx.fr>

The `ROOT_HOME` variable is natively absent from some systems, however the form
`~root`, which is used by the install functions in this same file, works.

* etc/guix-install.sh (sys_delete_store, sys_delete_guix_daemon)
(sys_delete_user_profiles): Replace `ROOT_HOME` with `~root`.

Change-Id: Ia867e271ac4c5557d9708235fee028bccce68342
---
 etc/guix-install.sh | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/etc/guix-install.sh b/etc/guix-install.sh
index e97190d964..7fb5ac63c5 100755
--- a/etc/guix-install.sh
+++ b/etc/guix-install.sh
@@ -410,8 +410,8 @@ sys_delete_store()
     _msg "${INF}removing /gnu"
     rm -rf /gnu

-    _msg "${INF}removing ${ROOT_HOME}/.config/guix"
-    rm -rf ${ROOT_HOME}/.config/guix
+    _msg "${INF}removing ~root/.config/guix"
+    rm -rf ~root/.config/guix
 }

 sys_create_build_user()
@@ -594,7 +594,7 @@ sys_delete_guix_daemon()
             ;;
         NA|*)
             _msg "${ERR}unsupported init system; disable, stop and remove the daemon manually:"
-            echo "  ${ROOT_HOME}/.config/guix/current/bin/guix-daemon --build-users-group=guixbuild"
+            echo "  ~root/.config/guix/current/bin/guix-daemon --build-users-group=guixbuild"
             ;;
     esac

@@ -743,9 +743,9 @@ sys_delete_init_profile()

 sys_delete_user_profiles()
 {
-    _msg "${INF}removing ${ROOT_HOME}/.guix-profile"
-    rm -f ${ROOT_HOME}/.guix-profile
-    rm -rf ${ROOT_HOME}/.cache/guix
+    _msg "${INF}removing ~root/.guix-profile"
+    rm -f ~root/.guix-profile
+    rm -rf ~root/.cache/guix

     _msg "${INF}removing .guix-profile, .cache/guix and .config/guix of all /home users"
     for user in `ls -1 /home`; do
--
2.43.0





  parent reply	other threads:[~2024-11-08 18:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-08 13:41 [bug#74258] [PATCH 0/3] Fix uninstall script David Boilleau via Guix-patches via
2024-11-08 14:10 ` [bug#74258] [PATCH 1/3] guix-install.sh: Test if gnu-store.mount exists before removing the unit David Boilleau via Guix-patches via
2024-11-08 14:10 ` David Boilleau via Guix-patches via [this message]
2024-11-08 14:10 ` [bug#74258] [PATCH 3/3] guix-install.sh: Run the uninstall even if already partially done David Boilleau via Guix-patches via
2024-11-14 14:41 ` bug#74258: [PATCH 0/3] Fix uninstall script Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1a9aa88fcacc1c9b2f173a0aa8a6aa7327a3a2b7.1731055803.git.david_boilleau@gmx.fr \
    --to=guix-patches@gnu.org \
    --cc=74258@debbugs.gnu.org \
    --cc=david_boilleau@gmx.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).