summary refs log tree commit diff
path: root/doc
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2022-10-28 11:05:03 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2022-11-15 16:26:16 -0500
commit9b21cd2e9a614f1937769caf3917a791b151d841 (patch)
tree08071e907de6fbd7a6b296bebd1479d120768707 /doc
parent543d971ed2a1d9eb934af1f51930741d7cc4e7ef (diff)
downloadguix-9b21cd2e9a614f1937769caf3917a791b151d841.tar.gz
services: mcron: Add log? and log-format fields to mcron-configuration.
* gnu/services/mcron.scm (list-of-gexps?): New predicate.
(mcron-configuration): Rewrite using define-configuration.
[log?, log-format]: New fields.
(mcron-shepherd-services): Invoke mcron with the --log and --log-format
arguments when log? is #t,
(generate-doc): New procedure.
* doc/guix.texi (Scheduled Job Execution): Update doc.
(Mcron Home Service): Likewise.
* gnu/home/services/mcron.scm: Keep in sync with the above changes to
gnu/services/mcron.scm.
Diffstat (limited to 'doc')
-rw-r--r--doc/guix.texi45
1 files changed, 36 insertions, 9 deletions
diff --git a/doc/guix.texi b/doc/guix.texi
index 4d974be53e..ef3b8e127e 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -19019,20 +19019,33 @@ words, it is possible to define services that provide additional mcron
 jobs to run.
 @end defvr
 
+@c Generated via (generate-documentation) at the bottom of (gnu services
+@c mcron).
+@c %start of fragment
 @deftp {Data Type} mcron-configuration
-Data type representing the configuration of mcron.
+Available @code{mcron-configuration} fields are:
 
 @table @asis
-@item @code{mcron} (default: @var{mcron})
+@item @code{mcron} (default: @code{mcron}) (type: file-like)
 The mcron package to use.
 
-@item @code{jobs}
+@item @code{jobs} (default: @code{()}) (type: list-of-gexps)
 This is a list of gexps (@pxref{G-Expressions}), where each gexp
 corresponds to an mcron job specification (@pxref{Syntax, mcron job
-specifications,, mcron, GNU@tie{}mcron}).
+specifications,, mcron,GNU@tie{}mcron}).
+
+@item @code{log?} (default: @code{#t}) (type: boolean)
+Log messages to standard output.
+
+@item @code{log-format} (default: @code{"~1@@*~a ~a: ~a~%"}) (type: string)
+@code{(ice-9 format)} format string for log messages.  The default value
+produces messages like "@samp{@var{pid} @var{name}: @var{message}"}
+(@pxref{Invoking mcron, Invoking,, mcron,GNU@tie{}mcron}).  Each message
+is also prefixed by a timestamp by GNU Shepherd.
+
 @end table
 @end deftp
-
+@c %end of fragment
 
 @node Log Rotation
 @subsection Log Rotation
@@ -41068,18 +41081,32 @@ jobs to run.
 @end defvr
 
 @deftp {Data Type} home-mcron-configuration
-Data type representing the configuration of mcron.
+Available @code{home-mcron-configuration} fields are:
 
+@c Auto-generated with (gnu home services mcron)'s
+@c generate-documentation procedure.
+@c %start of fragment
 @table @asis
-@item @code{mcron} (default: @var{mcron})
+@item @code{mcron} (default: @code{mcron}) (type: file-like)
 The mcron package to use.
 
-@item @code{jobs}
+@item @code{jobs} (default: @code{()}) (type: list-of-gexps)
 This is a list of gexps (@pxref{G-Expressions}), where each gexp
 corresponds to an mcron job specification (@pxref{Syntax, mcron job
-specifications,, mcron, GNU@tie{}mcron}).
+specifications,, mcron,GNU@tie{}mcron}).
+
+@item @code{log?} (default: @code{#t}) (type: boolean)
+Log messages to standard output.
+
+@item @code{log-format} (default: @code{"~1@@*~a ~a: ~a~%"}) (type: string)
+@code{(ice-9 format)} format string for log messages.  The default value
+produces messages like "@samp{@var{pid} @var{name}: @var{message}"}
+(@pxref{Invoking mcron, Invoking,, mcron,GNU@tie{}mcron}).  Each message
+is also prefixed by a timestamp by GNU Shepherd.
+
 @end table
 @end deftp
+@c %end of fragment
 
 @node Power Management Home Services
 @subsection Power Management Home Services