all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* guix refresh only python-*
@ 2022-11-20 18:56 jgart
  2022-11-20 22:44 ` zimoun
  0 siblings, 1 reply; 4+ messages in thread
From: jgart @ 2022-11-20 18:56 UTC (permalink / raw)
  To: Guix Help

hi, how can I see only what python packages can be updated with guix refresh?

all best,

jgart


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: guix refresh only python-*
  2022-11-20 18:56 guix refresh only python-* jgart
@ 2022-11-20 22:44 ` zimoun
  2022-11-21  7:21   ` (
  0 siblings, 1 reply; 4+ messages in thread
From: zimoun @ 2022-11-20 22:44 UTC (permalink / raw)
  To: jgart, Guix Help

Hi,

On Sun, 20 Nov 2022 at 12:56, jgart <jgart@dismail.de> wrote:
> hi, how can I see only what python packages can be updated with guix refresh?

   guix refresh -m python-packages.scm -u

where python-packages.scm is adapted from [1], copied and pasted here:

--8<---------------cut here---------------start------------->8---
(use-modules (gnu packages)
             (guix build-system pyproject)
             (guix build-system python)
             (guix packages))

(fold-packages (lambda (pkg count)
                 (+ 1 count))
               0
               #:select?
               (lambda (pkg)
                 (and (not (hidden-package? pkg))
                      (member (package-build-system pkg)
                              (list pyproject-build-system
                                    python-build-system)))))
--8<---------------cut here---------------end--------------->8---

Instead of

               (lambda (pkg count)
                 (+ 1 count))

something like

               (lambda (pkg python-packages)
                 (cons pkg python-packages))

and the ’0’ initial value replaced by the empty list ’()’.

Here you get all the python packages.  Then, you just return a manifest,
something like,

        (manifest
         (map package->manifest-entry
              (fold-packages …
                                                          )))

1: https://yhetil.org/guix/COD5P19YLOOM.286HAM1U8M8MZ@guix-framework>

Cheers,
simon


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: guix refresh only python-*
  2022-11-20 22:44 ` zimoun
@ 2022-11-21  7:21   ` (
  2022-11-21 10:39     ` zimoun
  0 siblings, 1 reply; 4+ messages in thread
From: ( @ 2022-11-21  7:21 UTC (permalink / raw)
  To: zimoun, jgart, Guix Help

On Sun Nov 20, 2022 at 10:44 PM GMT, zimoun wrote:
>                (lambda (pkg python-packages)
>                  (cons pkg python-packages))

You could also just use ``cons'' here with the same effect.

    -- (


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: guix refresh only python-*
  2022-11-21  7:21   ` (
@ 2022-11-21 10:39     ` zimoun
  0 siblings, 0 replies; 4+ messages in thread
From: zimoun @ 2022-11-21 10:39 UTC (permalink / raw)
  To: (, jgart, Guix Help

Hi,

On Mon, 21 Nov 2022 at 07:21, "(" <paren@disroot.org> wrote:
> On Sun Nov 20, 2022 at 10:44 PM GMT, zimoun wrote:
>>                (lambda (pkg python-packages)
>>                  (cons pkg python-packages))
>
> You could also just use ``cons'' here with the same effect.

Yeah, for sure.  By definition of ’cons’. :-)

Cheers,
simon



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-11-21 11:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-20 18:56 guix refresh only python-* jgart
2022-11-20 22:44 ` zimoun
2022-11-21  7:21   ` (
2022-11-21 10:39     ` zimoun

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.