From: Bruno Victal <mirai@makinata.eu>
To: 62103@debbugs.gnu.org
Cc: ludo@gnu.org, Bruno Victal <mirai@makinata.eu>
Subject: [bug#62103] [PATCH 2/2] system: Remove redundant gexp-ungexp usage.
Date: Fri, 10 Mar 2023 20:21:22 +0000 [thread overview]
Message-ID: <8c537e38fc7bcb0eec2aa74bcaa73c1c4e49116d.1678479682.git.mirai@makinata.eu> (raw)
In-Reply-To: <cover.1678479194.git.mirai@makinata.eu>
* gnu/system.scm (os-release): Convert to variable.
(operating-system-etc-service): Remove redundant gexp-ungexps.
---
gnu/system.scm | 17 ++++++++---------
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/gnu/system.scm b/gnu/system.scm
index 2947d1321f..887e537b48 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -967,9 +967,8 @@ (define (validated-sudoers-file file)
"--check" "--file" #$file)
(copy-file #$file #$output)))))
-(define (os-release)
- (plain-file "os-release"
- "\
+(define os-release
+ (plain-file "os-release" "\
NAME=\"Guix System\"
ID=guix
PRETTY_NAME=\"Guix System\"
@@ -1092,15 +1091,15 @@ (define* (operating-system-etc-service os)
source /run/current-system/profile/etc/profile.d/bash_completion.sh
fi\n")))
(etc-service
- `(("os-release" ,#~#$(os-release))
+ `(("os-release" ,os-release)
("services" ,(file-append net-base "/etc/services"))
("protocols" ,(file-append net-base "/etc/protocols"))
("rpc" ,(file-append net-base "/etc/rpc"))
- ("login.defs" ,#~#$login.defs)
- ("issue" ,#~#$issue)
- ,@(if nsswitch `(("nsswitch.conf" ,#~#$nsswitch)) '())
- ("profile" ,#~#$profile)
- ("bashrc" ,#~#$bashrc)
+ ("login.defs" ,login.defs)
+ ("issue" ,issue)
+ ,@(if nsswitch `(("nsswitch.conf" ,nsswitch)) '())
+ ("profile" ,profile)
+ ("bashrc" ,bashrc)
;; Write the operating-system-host-name to /etc/hostname to prevent
;; NetworkManager from changing the system's hostname when connecting
;; to certain networks. Some discussion at
--
2.39.1
next prev parent reply other threads:[~2023-03-10 20:22 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-10 20:16 [bug#62103] [PATCH 0/2] redundant system degexp Bruno Victal
2023-03-10 20:21 ` [bug#62103] [PATCH 1/2] system: Simplify nsswitch binding Bruno Victal
2023-03-10 20:21 ` Bruno Victal [this message]
2023-03-13 11:30 ` bug#62103: [PATCH 2/2] system: Remove redundant gexp-ungexp usage 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=8c537e38fc7bcb0eec2aa74bcaa73c1c4e49116d.1678479682.git.mirai@makinata.eu \
--to=mirai@makinata.eu \
--cc=62103@debbugs.gnu.org \
--cc=ludo@gnu.org \
/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).