gwl-devel
[Top][All Lists]
Advanced

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

Re: [PATCH v3 1/1] packages: Support for full Guix specification


From: Olivier Dion
Subject: Re: [PATCH v3 1/1] packages: Support for full Guix specification
Date: Sun, 22 May 2022 08:33:46 -0400

On Sun, 22 May 2022, Ricardo Wurmus <rekado@elephly.net> wrote:
> Hi Olivier,
>
> thanks for the new patch and my apologies for the delay!
>
> It looks fine, but I can’t help but feel a little confused about what
> variables are actual package values and what are wrappers.  Sometimes we
> have a variable called “packages”, but it’s seemingly always going to be
> package wrappers, so we map “package-unwrap”.
>
> I wonder if there’s a way to hide this machinery somewhat.  On the other
> hand, “package-unwrap” is a no-op for actual packages, so it doesn’t
> really matter.

Hi.  I've think of a way to accomplish this without introducing anything
ad-hoc.  You will see in my next patch.  Basically, I use object
properties to mark a package with its output.  By doing so, we only need
to change the code that actually need the package's output, that is the
call to `packages->manifest'.  The rest of the code simply manipulates a
package as usual.  I think it's technique called data layering and is
awesome!

-- 
Olivier Dion
oldiob.dev



reply via email to

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