[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#40601] [PATCH 04/28] guix-install.sh: Handle local binary tarball f
From: |
Vincent Legoll |
Subject: |
[bug#40601] [PATCH 04/28] guix-install.sh: Handle local binary tarball file. |
Date: |
Sun, 17 May 2020 19:17:01 +0200 |
* etc/guix-install.sh (REQUIRE): add realpath.
(main): Handle local binary tarball file path passed as first arg.
---
etc/guix-install.sh | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/etc/guix-install.sh b/etc/guix-install.sh
index 4fa9664cf5..7b9a729570 100755
--- a/etc/guix-install.sh
+++ b/etc/guix-install.sh
@@ -4,6 +4,7 @@
# Copyright © 2018 Ricardo Wurmus <address@hidden>
# Copyright © 2018 Efraim Flashner <address@hidden>
# Copyright © 2019 Tobias Geerinckx-Rice <address@hidden>
+# Copyright © 2020 Vincent Legoll <address@hidden>
#
# This file is part of GNU Guix.
#
@@ -47,6 +48,7 @@ REQUIRE=(
"uname"
"groupadd"
"tail"
+ "realpath"
"tr"
"xz"
)
@@ -482,10 +484,14 @@ main()
umask 0022
tmp_path="$(mktemp -t -d guix.XXX)"
- guix_get_bin_list "${GNU_URL}"
- guix_get_bin "${GNU_URL}" "${BIN_VER}" "$tmp_path"
-
- sys_create_store "${BIN_VER}.tar.xz" "${tmp_path}"
+ if [ -z "$1" ]; then
+ guix_get_bin_list "${GNU_URL}"
+ guix_get_bin "${GNU_URL}" "${BIN_VER}" "${tmp_path}"
+ TARBALL="${BIN_VER}.tar.xz"
+ else
+ TARBALL="$(realpath $1)"
+ fi
+ sys_create_store "${TARBALL}" "${tmp_path}"
sys_create_build_user
sys_enable_guix_daemon
sys_authorize_build_farms
--
2.26.2
- [bug#40601] [PATCH 01/28] nix/local.mk: Add missing comment to sysvinit section., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 07/28] guix-install.sh: Move code in a new function., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 04/28] guix-install.sh: Handle local binary tarball file.,
Vincent Legoll <=
- [bug#40601] [PATCH 02/28] guix-install.sh: Add xz to requirements., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 03/28] guix-install.sh: Fix systemctl not found error message at probe., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 06/28] guix-install.sh: trivial whitespace fix., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 08/28] guix-install.sh: Use getent for both user & group presence checking., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 05/28] guix-install.sh, guix-binary tarball: Handle runit-based foreign distributions., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 10/28] guix-install.sh: Replace subshell-inducing command grouping., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 12/28] guix-install.sh: Rework user & group handling, adding busybox support., Vincent Legoll, 2020/05/17
- [bug#40601] [PATCH 13/28] guix-install.sh: Make grep & mktemp usage compatible with busybox., Vincent Legoll, 2020/05/17