Subject: Re: bug#58660: [PATCH 0/4] Minor tweaks of etc/teams.scm

From: Maxim Cournoyer <[email-masked]>
Date: Tue, 29 Aug 2023 14:58:09 -0400

Hi,

zimoun <[email-masked]> writes:

> Hi Mathieu,
>
> On Fri, 18 Nov 2022 at 18:23, Mathieu Othacehe <[email-masked]> wrote:
>
>
>> Why not:
>>
>> (scope (format #f "scope:~%~{+ ~s ~}~%" scope))
>
> Because this does not “itemize” correctly.  For instance, it outputs:
>
> id: python
> name: Python team
> description: Python, Python packages, the "pypi" importer, and the python-build-system.
> scope:
> + "gnu/packages/django.scm" + "gnu/packages/jupyter.scm" + #<regexp 7f408800d500> + "gnu/packages/sphinx.scm" + "gnu/packages/tryton.scm" + "guix/build/pyproject-build-system.scm" + "guix/build-system/pyproject.scm" + "guix/build/python-build-system.scm" + "guix/build-system/python.scm" + "guix/import/pypi.scm" + "guix/scripts/import/pypi.scm" + "tests/pypi.scm" 
> members:
> + Lars-Dominik Braun <[email-masked]>
> + jgart <[email-masked]>
>
>
> When what we want is:
>
> scope:
> + "gnu/packages/django.scm"
> + "gnu/packages/jupyter.scm"
> + #<regexp 7f408800d500>
> + "gnu/packages/sphinx.scm"
> + "gnu/packages/tryton.scm"
> + "guix/build/pyproject-build-system.scm"
> + "guix/build-system/pyproject.scm"
> + "guix/build/python-build-system.scm"
> + "guix/build-system/python.scm"
> + "guix/import/pypi.scm"
> + "guix/scripts/import/pypi.scm"
> + "tests/pypi.scm" 
>
>
> Well, the ’~%’ is included:
>
>     (scope (format #f "scope:~%~{+ ~s~% ~}~%" scope))))
>
> then there is one extra:
>
> id: python
> name: Python team
> description: Python, Python packages, the "pypi" importer, and the python-build-system.
> scope:
> + "gnu/packages/django.scm"
>  + "gnu/packages/jupyter.scm"
>  + #<regexp 7f40de756500>
>  + "gnu/packages/sphinx.scm"
>  + "gnu/packages/tryton.scm"
>  + "guix/build/pyproject-build-system.scm"
>  + "guix/build-system/pyproject.scm"
>  + "guix/build/python-build-system.scm"
>  + "guix/build-system/python.scm"
>  + "guix/import/pypi.scm"
>  + "guix/scripts/import/pypi.scm"
>  + "tests/pypi.scm"
>  
> members:
> + Lars-Dominik Braun <[email-masked]>
> + jgart <[email-masked]>

That's fixable with the 'escape' escape, ~^:

--8<---------------cut here---------------start------------->8---
(format #f "scope:~%~{+ ~a~^~%~}~%" scope)
--8<---------------cut here---------------end--------------->8---

I've reworked your v2, integrating the comments from Mathieu and
installed it as 4d7b25a0e2abd77625cdc888c60da8e6add02bbd.

Closing!

-- 
Thanks,
Maxim