[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#26265: [PATCH 1/1] packages: Add optional `for-ui` param to `package
From: |
Ludovic Courtès |
Subject: |
bug#26265: [PATCH 1/1] packages: Add optional `for-ui` param to `package-full-name`. |
Date: |
Tue, 28 Mar 2017 17:06:51 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) |
Alex Sassmannshausen <address@hidden> skribis:
> * guix/packages.scm (package-full-name): Add optional parameter `for-ui`.
> * guix/scripts/refresh.scm (list-dependents): Use it.
> * tests/packages.scm: Add tests for `package-full-name`.
[...]
> +(define* (package-full-name package #:optional for-ui)
> + "Return the full name of PACKAGE--i.e., `NAME-VERSION'. If FOR-UI? is #t,
> +return the full name of PACKAGE using \"@\" as the NAME, VERSION separator."
I’d replace ‘for-ui’ with:
#:optional (separator "@")
I think it’s less ambiguous.
That also means that we’d need to change *non*-UI call sites, instead of
changing UI call sites. Hopefully there are few of them, but as
discussed in the other message, it takes manual analysis to determine
which use requires a hyphen and which one does not.
Thanks,
Ludo’.