[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] guix package: Export generation procedures.
From: |
Ludovic Courtès |
Subject: |
Re: [PATCH] guix package: Export generation procedures. |
Date: |
Sat, 04 Oct 2014 22:23:02 +0200 |
User-agent: |
Gnus/5.130011 (Ma Gnus v0.11) Emacs/24.3 (gnu/linux) |
Hi!
Alex Kost <address@hidden> skribis:
> What about the attached patch? Some comments and questions:
>
> - I added 'store' argument to the exported procedures, however it is
> used only in one particular case: when we need to create an empty
> profile (i.e. to call ‘link-to-empty-profile’). Is there a way to
> avoid using 'store' argument there or is it fine to leave it like
> this?
For now it’s fine to leave it like this, with the ‘store’ argument.
Eventually it should be changed to use the monadic style, though.
> - I actually need only ‘delete-generations’ procedure for Emacs UI, but
> I think other procedures are also worth to be exported or not?
Yes, sure.
> - Perhaps there is a better place for those functions than
> (guix scripts package)?
Yes, (guix profiles) would be a better place IMO.
> - (Not related to this patch, but still …) Currently with “roll-back”,
> we can only switch to the previous generation. What about adding a
> possibility to switch to any generation? So that we could use
> something like this:
>
> guix package --switch-generation=7
>
> Also such functionality can be added to Emacs UI: for example pressing
> "C" on a generation in *Guix Generation List* will make this
> generation the current one.
>
> So ‘roll-back’ procedure may become a special case of the
> ‘switch-generation’ one. WDYT?
I think it’s a good idea! (I think it was suggested in earlier
discussions, but never implemented.)
> From c50d1674d3be699198afb649a2a9932ca44c89bc Mon Sep 17 00:00:00 2001
> From: Alex Kost <address@hidden>
> Date: Sat, 4 Oct 2014 20:45:35 +0400
> Subject: [PATCH] guix package: Export generation procedures.
>
> * guix/scripts/package.scm: Export 'roll-back', 'delete-generation',
> 'delete-generations'.
> (link-to-empty-profile, roll-back): Add 'store' argument.
> (delete-generations): New procedure.
> (guix-package): Adjust accordingly.
> [delete-generation]: Move to the top level. Add 'store' and 'profile'
> arguments.
> [display-and-delete]: Move to 'delete-generation'.
OK to commit.
To sum up, I would imagine two followups to this:
1. Move these procedures to (guix profiles).
2. Convert them to monadic style.
WDYT?
Thanks,
Ludo’.
- [PATCH] guix package: Export generation procedures., Alex Kost, 2014/10/04
- Re: [PATCH] guix package: Export generation procedures.,
Ludovic Courtès <=
- [PATCH] emacs: Add support for deleting generations., Alex Kost, 2014/10/05
- Re: [PATCH] emacs: Add support for deleting generations., Ludovic Courtès, 2014/10/05
- Re: [PATCH] emacs: Add support for deleting generations., Alex Kost, 2014/10/05
- Re: [PATCH] emacs: Add support for deleting generations., Ludovic Courtès, 2014/10/05
- Re: [PATCH] emacs: Add support for deleting generations., Alex Kost, 2014/10/05
- Re: [PATCH] emacs: Add support for deleting generations., Ludovic Courtès, 2014/10/06
[PATCH] guix package: Add '--switch-generation' option., Alex Kost, 2014/10/06