all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#62007] doc: User Accounts: Refine user-account and user-group
@ 2023-03-06 17:25 Wicki Gabriel (wicg)
  2023-03-08 20:53 ` Liliana Marie Prikler
  0 siblings, 1 reply; 3+ messages in thread
From: Wicki Gabriel (wicg) @ 2023-03-06 17:25 UTC (permalink / raw)
  To: 62007


[-- Attachment #1.1: Type: text/plain, Size: 335 bytes --]

Hi

I've stumbled upon some room for improvement considering where to add groups to a Guix system. Chapter 12.6 mentions the needed forms but lacks clear indication which operating-system​ fields to add these to.

My patch takes care of that.

This patch is based on commit 7bbeaa87e3796d56cc762dcfbc340f9be301d5f6

TIA,
g

[-- Attachment #1.2: Type: text/html, Size: 2340 bytes --]

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-doc-User-Accounts-Refine-user-account-and-user-group.patch --]
[-- Type: text/x-patch; name="0001-doc-User-Accounts-Refine-user-account-and-user-group.patch", Size: 2231 bytes --]

From 3bb4a0990906d227d77819d404864adef652933c Mon Sep 17 00:00:00 2001
From: gabriel <gabriel@erlikon.ch>
Date: Mon, 6 Mar 2023 18:04:17 +0100
Subject: [PATCH] doc: User Accounts: Refine user-account and user-group
 examples

* doc/guix.texi (User Accounts): Show where the user-account and user-group
forms belong within the operation-system context.
---
 doc/guix.texi | 27 ++++++++++++++++-----------
 1 file changed, 16 insertions(+), 11 deletions(-)

diff --git a/doc/guix.texi b/doc/guix.texi
index 6671ba9305..de34ca7ff4 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -17388,18 +17388,21 @@ $ sudo filefrag -e /swapfile | grep '^ *0:' | cut -d: -f3 | cut -d. -f1
 @cindex accounts
 @cindex user accounts
 User accounts and groups are entirely managed through the
-@code{operating-system} declaration.  They are specified with the
-@code{user-account} and @code{user-group} forms:
+@code{operating-system} declaration.  They are specified with
+@code{user-account} forms in the @code{users}-field and
+@code{user-group} forms in the @code{groups}-field:
 
 @lisp
-(user-account
-  (name "alice")
-  (group "users")
-  (supplementary-groups '("wheel"   ;allow use of sudo, etc.
-                          "audio"   ;sound card
-                          "video"   ;video devices such as webcams
-                          "cdrom")) ;the good ol' CD-ROM
-  (comment "Bob's sister"))
+(users (cons*
+         (user-account
+           (name "alice")
+           (group "users")
+           (supplementary-groups '("wheel"   ;allow use of sudo, etc.
+                                   "audio"   ;sound card
+                                   "video"   ;video devices such as webcams
+                                   "cdrom")) ;the good ol' CD-ROM
+           (comment "Bob's sister"))
+         %base-user-accounts))
 @end lisp
 
 Here's a user account that uses a different shell and a custom home
@@ -17519,7 +17522,9 @@ Guile Reference Manual}, for information on Guile's @code{crypt} procedure.
 User group declarations are even simpler:
 
 @lisp
-(user-group (name "students"))
+(groups (cons*
+         (user-group (name "students"))
+         %base-groups))
 @end lisp
 
 @deftp {Data Type} user-group
-- 
2.39.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [bug#62007] doc: User Accounts: Refine user-account and user-group
  2023-03-06 17:25 [bug#62007] doc: User Accounts: Refine user-account and user-group Wicki Gabriel (wicg)
@ 2023-03-08 20:53 ` Liliana Marie Prikler
  2023-06-06 14:23   ` bug#62007: " Josselin Poiret via Guix-patches via
  0 siblings, 1 reply; 3+ messages in thread
From: Liliana Marie Prikler @ 2023-03-08 20:53 UTC (permalink / raw)
  To: Wicki Gabriel (wicg), 62007

Am Montag, dem 06.03.2023 um 17:25 +0000 schrieb Wicki Gabriel (wicg):
> Hi
> 
> I've stumbled upon some room for improvement considering where to add
> groups to a Guix system. Chapter 12.6 mentions the needed forms but
> lacks clear indication which operating-system​ fields to add these
> to.
Note that user-account and user-group are also valid outside those
fields, e.g. as part of service configurations.  Also, an example has
already been given in section 12.1.

Cheers





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#62007: doc: User Accounts: Refine user-account and user-group
  2023-03-08 20:53 ` Liliana Marie Prikler
@ 2023-06-06 14:23   ` Josselin Poiret via Guix-patches via
  0 siblings, 0 replies; 3+ messages in thread
From: Josselin Poiret via Guix-patches via @ 2023-06-06 14:23 UTC (permalink / raw)
  To: Liliana Marie Prikler, Wicki Gabriel (wicg), 62007-done

[-- Attachment #1: Type: text/plain, Size: 325 bytes --]

Hi everyone,

I agree with Lily here, this should document only the user-account and
user-group records, not specific fields of operating-system which is
already documented in "(guix) operating-system Reference".

Closing, but feel free to continue the discussion if it's still unclear.

Best,
-- 
Josselin Poiret

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 682 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-06-06 14:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-06 17:25 [bug#62007] doc: User Accounts: Refine user-account and user-group Wicki Gabriel (wicg)
2023-03-08 20:53 ` Liliana Marie Prikler
2023-06-06 14:23   ` bug#62007: " Josselin Poiret via Guix-patches via

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.