Subject: Re: [bug#68412] [PATCH v2] scripts: edit: Accept generic formatting parameter.

From: Simon Tournier <[email-masked]>
Date: Wed, 14 Feb 2024 12:19:43 +0100

Hi,

On mar., 13 févr. 2024 at 16:04, Liliana Marie Prikler <[email-masked]> wrote:

>> 1. I think that the current placeholder can be confusing (quote vs
>> double-quote).
>
> Is this something we can fix by pointing out the single quotes, or is
> it better not to try that?

Well, even if it would be using Gash, the issue quote/double-quote would
be still there because it is too late – it does not depend on Guix
internals but only user Shell script.

If you are envisioning the user Shell would be Gash, well for what it is
worth, I am not convinced that – as an user – I would switch; I will
still use Bash, almost surely. ;-)

Therefore, GUIX_EDITOR_LOCATION_FORMAT needs to support Bash compatible
syntax.  And thus, the placeholder will stay – at least for backward
compatibility.

I propose {LINE} because it seems familiar with ${LINE}.  Or I proposed
<LINE>.  Ludo proposes %LINE%.

Last, I am not sure to understand the idea behind Gash.  And if is
something about Guix internals, then the best will be to have an
internal replacement from ’PLACEHOLDER’ to ’${PLACEHOLDER}’ and not to
have something that the user Shell can interpret.

All in all, IMHO, let pick one of them: {LINE} <LINE> %LINE% :-)

Cheers,
simon