From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alex Kost Subject: Re: [ANN] Emacs-Guix 0.4 Date: Thu, 24 May 2018 20:21:16 +0300 Message-ID: <87muwphsvn.fsf@gmail.com> References: <878t8f7qfk.fsf@gmail.com> <87y3gekkdu.fsf@gmail.com> <8736yixucx.fsf@gnu.org> <874liygt8b.fsf@gmail.com> <87y3g9uu3f.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:50236) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fLtvW-0001oY-4S for help-guix@gnu.org; Thu, 24 May 2018 13:21:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fLtvR-0004AO-7b for help-guix@gnu.org; Thu, 24 May 2018 13:21:22 -0400 In-Reply-To: <87y3g9uu3f.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Thu, 24 May 2018 14:16:36 +0200") List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: Ludovic =?utf-8?Q?Court=C3=A8s?= Cc: help-guix@gnu.org Ludovic Court=C3=A8s (2018-05-24 14:16 +0200) wrote: > Hello! > > Alex Kost skribis: > >> Ludovic Court=C3=A8s (2018-05-23 17:30 +0200) wrote: > > [...] > >>> I think =E2=80=98guix-dependent-packages=E2=80=99 is going to be very u= seful. I wonder >>> if we could have =E2=80=98C-u guix-dependent-packages=E2=80=99 list onl= y 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=E2=80=99s no such command. Perhaps something to add to =E2=80= =98guix refresh > -l=E2=80=99, say =E2=80=98guix refresh -l direct=E2=80=99? 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))))) > > =E2=80=98node-transitive-edges=E2=80=99 traverses the whole DAG, so you s= hould simply > call =E2=80=98edges=E2=80=99 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 :-) --=20 Alex