Subject: bug#21399: Emacs: Guix Package Info omits some inputs

From: [email-masked] (Ludovic Courtès)
Date: Thu, 03 Sep 2015 16:41:33 +0200

Alex Kost <[email-masked]> skribis:

> Yes, you are right, it is filtered in ‘package-inputs-names’ in
> "emacs/guix-main.scm".  The easiest fix would be the following
>
> diff --git a/emacs/guix-main.scm b/emacs/guix-main.scm
> index 8d3a881..636d524 100644
> --- a/emacs/guix-main.scm
> +++ b/emacs/guix-main.scm
> @@ -245,7 +245,7 @@ Example:
>  (define (package-inputs-names inputs)
>    "Return a list of full names of the packages from package INPUTS."
>    (filter-map (match-lambda
> -               ((_ (? package? package))
> +               ((_ (? package? package) _ ...)
>                  (package-full-name package))
>                 (_ #f))
>                inputs))
>
> However, I think it would be better to have "icedtea6-1.13.7:jdk"
> instead of "icedtea6-1.13.7" in the "Inputs".  This requires modifying
> ‘full-name->name+version’ procedure so that pressing such
> "<name>-<version>:<out>" buttons will also work.

Right, makes sense.

> From ae9203234d5254a9cb6a8127d31e99289c605f7a Mon Sep 17 00:00:00 2001
> From: Alex Kost <[email-masked]>
> Date: Wed, 2 Sep 2015 17:57:58 +0300
> Subject: [PATCH] emacs: Add support for "triplet" package inputs.
>
> Fixes <http://bugs.gnu.org/21399>.
>
> * emacs/guix-main.scm (full-name->name+version): Adjust to handle
>   "name-version:output" string.
>   (package-inputs-names): Support ("name" package "output") inputs.

LGTM, thanks for the quick fix!

Ludo’.