Re: A friendlier API for operating-system declarations

2024-02-25 Thread antlers
Thanks for the detailed response c: The blocker is that AFAIK we can't tell if a record-field was defined as thunk-ed or delay-ed outside of the expansion of the `define-record-type*' form that defines it, nor programatically access it's getter/setter (the pair `(guix records)` defines, which acco

Re: A friendlier API for operating-system declarations

2024-02-25 Thread antlers
> I don't believe that the syntax achieves its goals without this > mechanism I just realized my example doesn't actually include a use of recursive cut after all (whoops), and finding only 2 uses in my code-base, am open to considering SRFI-26 sufficient. This helps somewhat, but was not the bloc

Re: A friendlier API for operating-system declarations

2024-02-25 Thread antlers
> That looks like a nice syntax indeed. Is the code behind it small > enough to include it in (guix records)? Small enough? Yes (<100 LOC, inc. a handful of comments and tests). Suitable? No, I introduced it as "moderately-cursed" for a reason >u< But I appreciate the sentiment c: 1.) It leaks

Re: A friendlier API for operating-system declarations

2024-02-24 Thread antlers
ch before exploring larger systems built on top of it). Anyway, I like your take, just fount it today and got to thinking-- thanks for putting it out there~ 1: From: https://github.com/AutumnalAntlers/old-guix-config/blob/main/modules/antlers/systems/transformations/yubi.scm 2: Like `cut`, but deeper: see the `<>` symbol nested deep within in the `users` clause of the Yubi example.

Re: A friendlier API for operating-system declarations

2024-02-24 Thread antlers
to study your macro to understand how you wrote > it. I've only written a handful of macro in my life, and came to lisp > via common lisp, from which I've learned quite a lot apprently bad > habits, so I'm lost in scheme-land. > > I'll study your system, thant _yo

Re: A friendlier API for operating-system declarations

2023-05-18 Thread antlers
Anecdotally, my personal configurations are built out of composable operating-system transformers that add packages, services, etc. through trees of inherited records. That's fairly straightforward for eg. adding packages, but becomes more complicated when you consider modifying service configurat