[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ANN] Emacs-Guix 0.4
From: |
Alex Kost |
Subject: |
Re: [ANN] Emacs-Guix 0.4 |
Date: |
Thu, 24 May 2018 20:21:16 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) |
Ludovic Courtès (2018-05-24 14:16 +0200) wrote:
> Hello!
>
> Alex Kost <address@hidden> skribis:
>
>> Ludovic Courtès (2018-05-23 17:30 +0200) wrote:
>
> [...]
>
>>> I think ‘guix-dependent-packages’ is going to be very useful. I wonder
>>> if we could have ‘C-u guix-dependent-packages’ list only packages that
>>> are direct dependents? That would be helpful in some situations.
>>
>> I agree! Is there a shell command for this? I mean I'd like to know
>> what Guile code can do this :-)
>
> No, there’s no such command. Perhaps something to add to ‘guix refresh
> -l’, say ‘guix refresh -l direct’?
It would be good!
>> Currently, the following code is used to get dependent packages:
>>
>> (with-store store
>> (run-with-store store
>> (mlet %store-monad ((edges (node-back-edges %bag-node-type
>> (all-packages))))
>> (return (node-transitive-edges packages edges)))))
>
> ‘node-transitive-edges’ traverses the whole DAG, so you should simply
> call ‘edges’ instead.
>
> HTH!
Yes, now it's clear, thanks!
I recalled that C-u prefix is already occupied by specifying an
arbitrary profile for the package commands. So, I'm afraid instead of
"C-u M-x guix-dependent-packages" there will be "M-x
guix-direct-dependent-packages".
Or maybe I should just break this dull "convention" (I mean "C-u" for
profiles) as probably no one uses it anyway :-)
--
Alex