GNU bug report logs - #30916
Request: add a short description field for os-configuration

Previous Next

Package: guix;

Reported by: Martin Castillo <castilma <at> uni-bremen.de>

Date: Fri, 23 Mar 2018 12:53:01 UTC

Severity: wishlist

Full log


View this message in rfc822 format

From: Danny Milosavljevic <dannym <at> scratchpost.org>
To: Martin Castillo <castilma <at> uni-bremen.de>
Cc: 30916 <at> debbugs.gnu.org, ng0 <ng0 <at> n0.is>
Subject: bug#30916: Request: add a short description field for os-configuration
Date: Sat, 24 Mar 2018 17:54:38 +0100
[Message part 1 (text/plain, inline)]
Hi Martin,

On Sat, 24 Mar 2018 14:56:03 +0100
Martin Castillo <castilma <at> uni-bremen.de> wrote:

> ng0 wrote:
> > So basically you want a field in the operating-system declaration where you
> > can _manually_ set a description of a certain maximum length which will be
> > added to the GRUB entry of the generated system generation?  
> yes

I wonder whether this description can be generated instead - we have all
the information we need - the packages, the users that are there etc.

Or a description could be generated only if a custom description is not specified.

In fact it's easy to add this and would be a nice intro project for a
person interested in Guix development.  I can mentor.

The thing used to fill the Guix bootloader entries is <boot-parameters>.

There's a procedure "operating-system-boot-parameters" which is used
to generate <boot-parameters> instances from an <operating-system>
declaration.

(operating-system-bootcfg calls operating-system-boot-parameters)
(perform-action calls operating-system-bootcfg)
(perform-action is in the top-level guix script)

<boot-parameters> are serialized to disk into:

/var/guix/profiles/system-704-link$ cat parameters 
(boot-parameters (version 0) (label "GNU with Linux-Libre 4.14.14 (beta)") (root-device "dayas:/") (kernel "/gnu/store/fnk2xhicbrjsvbq082p6x0ch6npkrg0z-linux-libre-4.14.14/bzImage") (kernel-arguments ("crashkernel=256M" "modprobe.blacklist=pcspkr,snd_pcsp" "quiet" "acpi_osi=Linux" "clocksource=acpi_pm" "allow-discards" "root_trim=yes")) (initrd "/gnu/store/nvhkdssz1m1p8xrggi78y8pd7jz4p3ng-raw-initrd/initrd") (bootloader-name grub) (store (device "dayas:/") (mount-point "/")))

But I wouldn't change the serialization format or what fields <boot-parameters> contain.

Just change operating-system-bootcfg to take a "description" parameter.
And change operating-system-boot-parameters to take a "description" parameter and
use it to calculate the label.

And change perform-action to calculate the value for to "description" parameter in this way:
- Taking it from <operating-system> (or the command line?) 
- Falling back to an automatic value (comparing it to the previous generation) otherwise.

That's it.
[Message part 2 (application/pgp-signature, inline)]

This bug report was last modified 3 years and 200 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.