Hi,

I'm using STON for all my light storage serialization needs, like the
Grafoscopio notebooks, and I also love it, as Russ stated in their mail
question, and I share with him a similar request: for my Brea[1] static
site generator I would like to store some BreaQuery objects as external
STON files, and recover them, so I can run the queries that
recreate/update the website easily. I could store them as Grafoscopio
notebooks, but I don't want to make Grafoscopio a prerequisite for Brea
or I could use Fuel, but I would like to store queries as a diff
friendly text based format. I have considered Metacello/Iceberg packages
to export code in a diff friendly format, but It maybe overkill. So I
would like to see if STON can serve me here too.

[1] https://mutabit.com/repos.fossil/brea/
[2] https://mutabit.com/repos.fossil/indieweb/

So far, I'm able to serialize a code block as a string using:

BreaQuery>>asStonModified
    self codeBlock: self codeBlock asString
    ^ STON toStringPretty: self

But I'm unable to populate a block from a string. There is any way to
make a string, lets say 'a + b', to become the code contents of a block,
ie: [a + b ] ?

Thanks,

Offray

Reply via email to