[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Return back original implementation for text-config serialization
From: |
Maxime Devos |
Subject: |
Re: Return back original implementation for text-config serialization |
Date: |
Sun, 09 Jan 2022 13:19:04 +0100 |
User-agent: |
Evolution 3.38.3-1 |
Andrew Tropin schreef op zo 09-01-2022 om 12:12 [+0300]:
> [...] There is another less generalized example, which demonstrates
> how
> serialization of sway configuration works right now.
>
> --8<---------------cut here---------------start------------->8---
> `((include ,(local-file "./sway/config"))
> (bindsym $mod+Ctrl+Shift+a exec
> ,(file-append emacs "/bin/emacsclient") -c --eval
> "'(eshell)'")
> (bindsym $mod+Ctrl+Shift+o "[class=\"IceCat\"]" kill)
> (input * ((xkb_layout us,ru)
> (xkb_variant dvorak,))))
> --8<---------------cut here---------------end--------------->8---
>
> would yield something like:
>
> --8<---------------cut here---------------start------------->8---
> include /gnu/store/408jwvh6wxxn1j85lj95fniih05gx5xj-config
> bindsym $mod+Ctrl+Shift+a exec /gnu/store/...-emacsclient -c --eval
> '(eshell)'
> bindsym $mod+Ctrl+Shift+o [class="IceCat"] kill
> input * {
> xkb_layout us,ru
> xkb_variant dvorak,
> }
> --8<---------------cut here---------------end--------------->8---
>
> The new text-config serialization implementation (after fee0bc
> commit)
> doesn't support gexps and tries to insert the literal content of the
> file in place where file-like object was used, which
>
> 1. Confuses the users. [...]
> 2. Looks strange implementation-wise. [...]
> (mixed-text-file ...
> "source \" "\n"
> #~(read-everything-from-file
> #$(computed-file "unecessary-file-name"
> #~#$(local-file "blabla.sh"))))
> when originally it was
> (mixed-text-file
> "source \" "\n"
> (local-file "blabla.sh"))
Can we have (mixed-text-file "source \" "\n" (local-file "blabla.sh"))
and the sway configuration you quoted? That syntax seems reasonable
and easy to use to me. But without reintroducing slurp-file-gexp.
Greetings,
Maxime.
signature.asc
Description: This is a digitally signed message part
Re: Return back original implementation for text-config serialization, Maxime Devos, 2022/01/09
Re: Return back original implementation for text-config serialization,
Maxime Devos <=
Re: Return back original implementation for text-config serialization, Ludovic Courtès, 2022/01/18
Re: Return back original implementation for text-config serialization, Andrew Tropin, 2022/01/26
Re: Return back original implementation for text-config serialization, Ludovic Courtès, 2022/01/24