guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#54293] [WIP] home: Add home-git-service-type


From: 宋文武
Subject: [bug#54293] [WIP] home: Add home-git-service-type
Date: Wed, 09 Mar 2022 20:18:32 +0800
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)

Maxime Devos <maximedevos@telenet.be> writes:

> 宋文武 schreef op ma 07-03-2022 om 22:51 [+0800]:
>> +           (for-each
>> +            (match-lambda
>> +              ((key value)
>> +               (simple-format #t "\t~a = ~s~%" key value)))
>
> What if I want to set the key 'bar' to the value 'foo bar ' (without
> teh quotes, but with the trailing space)?  If I do ‘git config
> 'foo.bar' "foo bar "’, then the following is added to .git/config:
>
> [foo]
>         bar = "foo bar "
>
> so it seems that some escaping may be necessary.

Yes, '~s' in the format string will use 'write' which will print strings
in double quotes with some escapes.  I think it's compatible with
gitconfig's requirement.

>
> Also, what character encoding does git expect .git/config expect it to
> be in?  UTF-8, whatever the current locale's encoding is, ...?

I guess it expect UTF-8, will do some tests later, thanks!





reply via email to

[Prev in Thread] Current Thread [Next in Thread]