[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
06/06: maint: Use a pretty version string in ISO and VM images.
From: |
guix-commits |
Subject: |
06/06: maint: Use a pretty version string in ISO and VM images. |
Date: |
Tue, 9 Aug 2022 09:18:51 -0400 (EDT) |
civodul pushed a commit to branch master
in repository guix.
commit fdafd404325413da4d5fdd717c84e57a51c60fe2
Author: Ludovic Courtès <ludo@gnu.org>
AuthorDate: Tue Aug 9 11:48:52 2022 +0200
maint: Use a pretty version string in ISO and VM images.
* gnu/system/examples/vm-image.tmpl: Use the 'GUIX_DISPLAYED_VERSION'
environment variable in 'label'.
* gnu/system/install.scm (%installation-os): Likewise.
* Makefile.am (release): Set 'GUIX_DISPLAYED_VERSION'.
---
Makefile.am | 6 ++++--
gnu/system/examples/vm-image.tmpl | 4 +++-
gnu/system/install.scm | 3 ++-
3 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index ac6df11c85..8df8222573 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -984,13 +984,14 @@ release: dist-with-updated-version all
-v1 --no-grafts --fallback
# Generate the ISO installation images.
for system in $(GUIX_SYSTEM_SUPPORTED_SYSTEMS) ; do
\
+ GUIX_DISPLAYED_VERSION="`git describe --match=v* | sed -'es/^v//v'`"
; \
image=`$(top_builddir)/pre-inst-env
\
- guix system image -t iso9660
\
+ guix system image -t iso9660
\
--label="GUIX_$${system}_$(VERSION)"
\
--system=$$system --fallback
\
gnu/system/install.scm` ;
\
if [ ! -f "$$image" ] ; then
\
- echo "failed to produce Guix installation image for $$system" >&2 ;
\
+ echo "failed to produce Guix installation image for $$system" >&2 ;
\
exit 1 ;
\
fi ;
\
cp "$$image"
"$(releasedir)/$(GUIX_SYSTEM_IMAGE_BASE).$$system.iso.tmp" ; \
@@ -999,6 +1000,7 @@ release: dist-with-updated-version all
done
# Generate the VM images.
for system in $(GUIX_SYSTEM_VM_SYSTEMS) ; do
\
+ GUIX_DISPLAYED_VERSION="`git describe --match=v* | sed -'es/^v//v'`"
; \
image=`$(top_builddir)/pre-inst-env
\
guix system image -t qcow2 $(GUIX_SYSTEM_VM_IMAGE_FLAGS)
\
--save-provenance
\
diff --git a/gnu/system/examples/vm-image.tmpl
b/gnu/system/examples/vm-image.tmpl
index c8449c6e95..d46a27978c 100644
--- a/gnu/system/examples/vm-image.tmpl
+++ b/gnu/system/examples/vm-image.tmpl
@@ -43,7 +43,9 @@ accounts.\x1b[0m
(keyboard-layout (keyboard-layout "us" "altgr-intl"))
;; Label for the GRUB boot menu.
- (label (string-append "GNU Guix " (package-version guix)))
+ (label (string-append "GNU Guix "
+ (or (getenv "GUIX_DISPLAYED_VERSION")
+ (package-version guix))))
(firmware '())
diff --git a/gnu/system/install.scm b/gnu/system/install.scm
index 32b9f52e04..a7b7c246bf 100644
--- a/gnu/system/install.scm
+++ b/gnu/system/install.scm
@@ -469,7 +469,8 @@ Access documentation at any time by pressing Alt-F2.\x1b[0m
(bootloader grub-bootloader)
(targets '("/dev/sda"))))
(label (string-append "GNU Guix installation "
- (package-version guix)))
+ (or (getenv "GUIX_DISPLAYED_VERSION")
+ (package-version guix))))
;; XXX: The AMD Radeon driver is reportedly broken, which makes kmscon
;; non-functional:
- branch master updated (0d9eef0a06 -> fdafd40432), guix-commits, 2022/08/09
- 02/06: build-system/channel: Accept a channel or instance as the source., guix-commits, 2022/08/09
- 03/06: channels: Add 'repository->guix-channel'., guix-commits, 2022/08/09
- 01/06: build-system: Add 'channel-build-system'., guix-commits, 2022/08/09
- 05/06: system: install: Always use 'current-guix'., guix-commits, 2022/08/09
- 06/06: maint: Use a pretty version string in ISO and VM images.,
guix-commits <=
- 04/06: gnu: guix: Default 'current-guix' is built using the current channels., guix-commits, 2022/08/09