Subject: [bug#76063] [PATCH 1/3] services: Add ‘system-log’ Shepherd service.

From: Ludovic Courtès <[email-masked]>
Date: Fri, 14 Feb 2025 00:14:33 +0100

Hi!

I’ve sent v2, which addresses all the points you raised, with one
exception:

Maxim Cournoyer <[email-masked]> skribis:

>> +                             ;; XXX: As of Shepherd 1.0.1,
>> +                             ;; 'default-message-destination-procedure' is not
>> +                             ;; exported, hence this conditional.
>
> Perhaps check if we have shepherd >= 1.0.2 (?) and put the
> forward-looking code in this case, with the other code path ready to be
> removed after some time, if it's easy to check for the shepherd version.
>
>> +                             #$@(match (system-log-configuration-message-destination
>> +                                        config)
>> +                                  (#f #~())
>> +                                  (value #~(#:message-destination #$value)))

I kept it as is because we cannot really do what you describe: the
conditional would need to go in the default value of
‘message-destination’, like:

  #~(if (defined? 'default-message-destination-procedure)
        (default-message-destination-procedure)
        #f)

But if we did that it’d be hard to not pass #:message-destination in the
#f case.

(Not sure if I’m being clear, I hope you get the idea. :-))

Thanks for looking at it!

Ludo’.