* [bug#47163] Using package transformations declaratively (was: [bug#47163] [PATCH] refresh: Add '--installed' option.)
[not found] ` <87tupb8nzs.fsf@gnu.org>
@ 2021-03-16 16:44 ` Xinglu Chen
2021-03-16 17:23 ` zimoun
0 siblings, 1 reply; 4+ messages in thread
From: Xinglu Chen @ 2021-03-16 16:44 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: guix-devel, 47163
On Tue, Mar 16 2021, Ludovic Courtès wrote:
> You may also like the new ‘--with-latest’ package transformation
> option. :-)
I really like package transformations but is there a way to use specify
them with Guile so I can use them with `guix home`[1] or in manifests?
Ccing guix-devel
[1]: https://yhetil.org/guix-devel/878s6u2pco.fsf@trop.in
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [bug#47163] Using package transformations declaratively (was: [bug#47163] [PATCH] refresh: Add '--installed' option.)
2021-03-16 16:44 ` [bug#47163] Using package transformations declaratively (was: [bug#47163] [PATCH] refresh: Add '--installed' option.) Xinglu Chen
@ 2021-03-16 17:23 ` zimoun
2021-03-16 18:35 ` Xinglu Chen
2021-03-17 17:17 ` [bug#47163] Using package transformations declaratively Ludovic Courtès
0 siblings, 2 replies; 4+ messages in thread
From: zimoun @ 2021-03-16 17:23 UTC (permalink / raw)
To: Xinglu Chen; +Cc: Guix Devel, 47163
Hi,
On Tue, 16 Mar 2021 at 17:46, Xinglu Chen <public@yoctocell.xyz> wrote:
> On Tue, Mar 16 2021, Ludovic Courtès wrote:
>
> > You may also like the new ‘--with-latest’ package transformation
> > option. :-)
>
> I really like package transformations but is there a way to use specify
> them with Guile so I can use them with `guix home`[1] or in manifests?
There is several ways to have package transformations at the manifest
level. One is:
--8<---------------cut here---------------start------------->8---
(use-modules (guix transformations))
(define transform1
(options->transformation
'((with-c-toolchain . "hello=gcc-toolchain@8"))))
(packages->manifest
(list (transform1 (specification->package "hello"))))
--8<---------------cut here---------------end--------------->8---
HTH,
simon
^ permalink raw reply [flat|nested] 4+ messages in thread
* [bug#47163] Using package transformations declaratively (was: [bug#47163] [PATCH] refresh: Add '--installed' option.)
2021-03-16 17:23 ` zimoun
@ 2021-03-16 18:35 ` Xinglu Chen
2021-03-17 17:17 ` [bug#47163] Using package transformations declaratively Ludovic Courtès
1 sibling, 0 replies; 4+ messages in thread
From: Xinglu Chen @ 2021-03-16 18:35 UTC (permalink / raw)
To: zimoun; +Cc: Guix Devel, 47163
On Tue, Mar 16 2021, zimoun wrote:
>> I really like package transformations but is there a way to use specify
>> them with Guile so I can use them with `guix home`[1] or in manifests?
>
> There is several ways to have package transformations at the manifest
> level. One is:
>
> --8<---------------cut here---------------start------------->8---
> (use-modules (guix transformations))
>
> (define transform1
> (options->transformation
> '((with-c-toolchain . "hello=gcc-toolchain@8"))))
>
> (packages->manifest
> (list (transform1 (specification->package "hello"))))
> --8<---------------cut here---------------end--------------->8---
Cool, thanks for the help.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [bug#47163] Using package transformations declaratively
2021-03-16 17:23 ` zimoun
2021-03-16 18:35 ` Xinglu Chen
@ 2021-03-17 17:17 ` Ludovic Courtès
1 sibling, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2021-03-17 17:17 UTC (permalink / raw)
To: zimoun; +Cc: Guix Devel, Xinglu Chen, 47163
Hi,
zimoun <zimon.toutoune@gmail.com> skribis:
> There is several ways to have package transformations at the manifest
> level. One is:
>
> (use-modules (guix transformations))
>
> (define transform1
> (options->transformation
> '((with-c-toolchain . "hello=gcc-toolchain@8"))))
>
> (packages->manifest
> (list (transform1 (specification->package "hello"))))
On this topic, do not miss this section of the fine manual:
<https://guix.gnu.org/manual/en/html_node/Defining-Package-Variants.html>.
:-)
Ludo’.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2021-03-17 17:53 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bbf925b124979bf1203f3619d06dc51948b0f81e.1615822877.git.public@yoctocell.xyz>
[not found] ` <87tupb8nzs.fsf@gnu.org>
2021-03-16 16:44 ` [bug#47163] Using package transformations declaratively (was: [bug#47163] [PATCH] refresh: Add '--installed' option.) Xinglu Chen
2021-03-16 17:23 ` zimoun
2021-03-16 18:35 ` Xinglu Chen
2021-03-17 17:17 ` [bug#47163] Using package transformations declaratively Ludovic Courtès
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).