Subject: [bug#74801] [PATCH v4] gnu: home: services: Add home-mpv-service-type.

From: Tomas Volf <[email-masked]>
Date: Fri, 23 May 2025 14:50:47 +0200

Hi Sergey,

Sergey Trofimov <[email-masked]> writes:

> Hi Tomas,
>
> Tomas Volf <[email-masked]> writes:
>
>> This commit adds a new service type to generate configuration file for the mpv
>> media player.
>>
>
> I've just noticed this got merged and tried to use it in my config. I've
> mostly translated the config, but stumbled on the scripts settings:
>
> (service home-mpv-service-type
>         (make-home-mpv-configuration
>          #:global (make-mpv-profile-configuration
>                     #:scripts
>                     (list
>                      (file-append #$mpv-mpris "/lib/mpris.so")
>                      (file-append #$mpv-thumbfast "/share/mpv/scripts/thumbfast.lua")
>                      (file-append #$mpv-uosc "/share/mpv/scripts/uosc")))))
>
> Such config doesn't work as `scripts` option is of `list-of-string`
> type. I've also tried to workaround with `#:extra-config #~(...)`, but
> this didn't work either, raising an error in `string-suffix?`.
>
> To make it work, I think a new "file" type is necessary, which would
> allow gexps. Options that are marked as "[file]" (`mpv --list-options |
> grep -F "[file]"`) should assume this new type.

I agree.  Could you please report this as a separate bug and CC me on
it?  I will take a look, hopefully over the weekend.

Thanks,
Tomas

-- 
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.