From: Efraim Flashner <efraim@flashner.co.il>
To: SuarezMiguelC <SuarezMiguelC@protonmail.com>
Cc: "help-guix@gnu.org" <help-guix@gnu.org>
Subject: Re: New reconfigure, creating a file under /etc
Date: Mon, 7 Oct 2019 10:03:05 +0300 [thread overview]
Message-ID: <20191007070305.GI561@E5400> (raw)
In-Reply-To: <z8ldnvlgtxxLvvuYHXAOZcGNZKob3ayoZrmjTK1MvhC1mOGnNFhaY2hskVNlTLWfS6yOevFlp-UZMdCBP75MReu1LiIF_gsLb1np724Y0Ig=@protonmail.com>
[-- Attachment #1: Type: text/plain, Size: 1594 bytes --]
Here's the code I have for /etc/os-release. I defined %os-release-file
at the top to keep my actual services list a bit shorter. The '@'
notation is a short-cut to not need to actually import (guix packages)
or (gnu packages package-management) in my config.
Then later when adding the other services the 'simple-service' can just
be added in and it'll be combined with the other 'etc-service-type'
services to create a unified /etc.
(define %os-release-file
(plain-file "os-release"
(string-append
"NAME=\"Guix System\"\n"
"PRETTY_NAME=\"Guix System\"\n"
"VERSION=\""((@ (guix packages) package-version) (@ (gnu packages package-management) guix))"\"\n"
"ID=guix\n"
"HOME_URL=\"https://www.gnu.org/software/guix/\"\n"
"SUPPORT_URL=\"https://www.gnu.org/software/guix/help/\"\n"
"BUG_REPORT_URL=\"mailto:bug-guix@gnu.org\"\n")))
(simple-service 'os-release etc-service-type
`(("os-release" ,%os-release-file)))
and here's what it looks like:
efraim@E5400 ~$ cat /etc/os-release
NAME="Guix System"
PRETTY_NAME="Guix System"
VERSION="1.0.1-6.0ed97e6"
ID=guix
HOME_URL="https://www.gnu.org/software/guix/"
SUPPORT_URL="https://www.gnu.org/software/guix/help/"
BUG_REPORT_URL="mailto:bug-guix@gnu.org"
--
Efraim Flashner <efraim@flashner.co.il> אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2019-10-07 7:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-07 0:12 New reconfigure, creating a file under /etc SuarezMiguelC via
2019-10-07 2:12 ` John Soo
2019-10-07 6:30 ` Gábor Boskovits
2019-10-07 7:03 ` Efraim Flashner [this message]
2019-10-09 8:11 ` Giovanni Biscuolo
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191007070305.GI561@E5400 \
--to=efraim@flashner.co.il \
--cc=SuarezMiguelC@protonmail.com \
--cc=help-guix@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 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.