unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Xinglu Chen <public@yoctocell.xyz>
To: 48934@debbugs.gnu.org
Cc: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Subject: [bug#48934] [PATCH 0/2] Some improvements to (gnu services configuration)
Date: Wed, 09 Jun 2021 15:04:31 +0200	[thread overview]
Message-ID: <cover.1623243063.git.public@yoctocell.xyz> (raw)

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

This series contains some improvements to the (gnu services
configuration) module.

The first patch changes the formatting of the generated documentation
for configuration records.  Previously, the generated documentation
looked a bit different from the ones that were to generated, compare the
docs for ‘getmail-configuration’ (generated) and ‘openssh-configuration’
(not generated).

--8<---------------cut here---------------start------------->8---
   Available ‘getmail-configuration’ fields are:

 -- ‘getmail-configuration’ parameter: symbol name
     A symbol to identify the getmail service.

     Defaults to ‘"unset"’.

 -- ‘getmail-configuration’ parameter: package package
     The getmail package to use.
--8<---------------cut here---------------end--------------->8---

--8<---------------cut here---------------start------------->8---
 -- Data Type: openssh-configuration
     This is the configuration record for OpenSSH’s ‘sshd’.

     ‘openssh’ (default OPENSSH)
          The Openssh package to use.

     ‘pid-file’ (default: ‘"/var/run/sshd.pid"’)
          Name of the file where ‘sshd’ writes its PID.

     ‘port-number’ (default: ‘22’)
          TCP port on which ‘sshd’ listens for incoming connections.
--8<---------------cut here---------------end--------------->8---

The first patch will make the generated documentation look at lot more
similiar to the hand-written ones.

--8<---------------cut here---------------start------------->8---
 -- Data Type: getmail-configuration
     Available ‘getmail-configuration’ fields are:

     ‘name’ (default: ‘"unset"’) (type: symbol)
          A symbol to identify the getmail service.

     ‘package’ (default: ‘getmail’) (type: package)
          The getmail package to use.
--8<---------------cut here---------------end--------------->8---

If you paid close attention you will also notice that the old generated
docs didn’t specify the default value of the ‘package’ field, whereas
the new docs do.  This brings us to the second patch, it looks the
package and shows the value of the ‘name’ field of the package.  This
will only show the correct package name if the ‘name’ field and the
Scheme variable corresponding to the package are the same, in most cases
it is, so I don’t think it would be a huge deal.

Xinglu Chen (2):
  services: configuration: Change formatting of generated documentation.
  services: configuration: Show default value when it is a package.

 gnu/services/configuration.scm | 62 ++++++++++++++++++++--------------
 1 file changed, 36 insertions(+), 26 deletions(-)


base-commit: 86bb77608d375043f837583332a7c852ea2080ec
-- 
2.32.0



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

             reply	other threads:[~2021-06-09 13:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-09 13:04 Xinglu Chen [this message]
2021-06-09 13:06 ` [bug#48934] [PATCH 1/2] services: configuration: Change formatting of generated Xinglu Chen
2021-08-02 18:10   ` [bug#48934] [PATCH 0/2] Some improvements to (gnu services configuration) Maxim Cournoyer
2021-06-09 13:06 ` [bug#48934] [PATCH 2/2] services: configuration: Show default value when it is a Xinglu Chen
2021-08-02 18:21   ` bug#48934: [PATCH 0/2] Some improvements to (gnu services configuration) Maxim Cournoyer
2021-08-03  7:24     ` [bug#48934] " Xinglu Chen
2021-08-03 14:38       ` Maxim Cournoyer

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=cover.1623243063.git.public@yoctocell.xyz \
    --to=public@yoctocell.xyz \
    --cc=48934@debbugs.gnu.org \
    --cc=maxim.cournoyer@gmail.com \
    /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).