* (length all-python-packages)
@ 2022-11-15 20:22 jgart
2022-11-15 20:36 ` (
0 siblings, 1 reply; 5+ messages in thread
From: jgart @ 2022-11-15 20:22 UTC (permalink / raw)
To: Guix Help
Hi,
How can I list how many Python packages we currently have in master?
What Guix APIs do you suggest that I hook into to determine this?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: (length all-python-packages)
2022-11-15 20:22 (length all-python-packages) jgart
@ 2022-11-15 20:36 ` (
2022-11-16 14:19 ` Andreas Enge
0 siblings, 1 reply; 5+ messages in thread
From: ( @ 2022-11-15 20:36 UTC (permalink / raw)
To: jgart, Guix Help
On Tue Nov 15, 2022 at 8:22 PM GMT, jgart wrote:
> How can I list how many Python packages we currently have in master?
How about this:
(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)))))
For me, this returns "2749".
-- (
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: (length all-python-packages)
2022-11-15 20:36 ` (
@ 2022-11-16 14:19 ` Andreas Enge
2022-11-16 14:37 ` jgart
0 siblings, 1 reply; 5+ messages in thread
From: Andreas Enge @ 2022-11-16 14:19 UTC (permalink / raw)
To: (; +Cc: jgart, Guix Help
Hello,
Am Tue, Nov 15, 2022 at 08:36:35PM +0000 schrieb (:
> For me, this returns "2749".
more crudely, I tried this on the command line:
./pre-inst-env guix package -A ^python | wc
which returns 2165, or
./pre-inst-env guix package -A ^python- | wc
which excludes python2-packages and returns 2140, or
./pre-inst-env guix package -A ^python- | awk '{print $1}' | uniq | wc
which excludes duplicate package versions and returns 2091.
It looks like we have a lot of python packages that do not admit it
in their name :)
Andreas
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: (length all-python-packages)
2022-11-16 14:19 ` Andreas Enge
@ 2022-11-16 14:37 ` jgart
2022-11-16 14:44 ` Tobias Geerinckx-Rice
0 siblings, 1 reply; 5+ messages in thread
From: jgart @ 2022-11-16 14:37 UTC (permalink / raw)
To: Andreas Enge; +Cc: (, Guix Help
On Wed, 16 Nov 2022 15:19:10 +0100 Andreas Enge <andreas@enge.fr> wrote:
> Hello,
>
> Am Tue, Nov 15, 2022 at 08:36:35PM +0000 schrieb (:
> > For me, this returns "2749".
>
> more crudely, I tried this on the command line:
> ./pre-inst-env guix package -A ^python | wc
> which returns 2165, or
> ./pre-inst-env guix package -A ^python- | wc
> which excludes python2-packages and returns 2140, or
> ./pre-inst-env guix package -A ^python- | awk '{print $1}' | uniq | wc
> which excludes duplicate package versions and returns 2091.
>
> It looks like we have a lot of python packages that do not admit it
> in their name :)
>
> Andreas
>
Andreas and paren,
Thanks for the replies and examples. Much appreciated!
I imagine this does not include python packages like jrnl, khal, clikan, t-todo-manager, gajim etc?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: (length all-python-packages)
2022-11-16 14:37 ` jgart
@ 2022-11-16 14:44 ` Tobias Geerinckx-Rice
0 siblings, 0 replies; 5+ messages in thread
From: Tobias Geerinckx-Rice @ 2022-11-16 14:44 UTC (permalink / raw)
To: jgart; +Cc: Andreas Enge, (, help-guix
[-- Attachment #1: Type: text/plain, Size: 418 bytes --]
jgart 写道:
> I imagine this does not include python packages like jrnl, khal,
> clikan, t-todo-manager, gajim etc?
Yep.
If you need more reliable numbers, use ('s code snippet: there
will be a handful of false negatives (e.g., packages written in
Python that prefer to use Makefiles, or that mix phases from
different build systems) but that number will be insignificant.
Kind regards,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 247 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-11-16 14:48 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-15 20:22 (length all-python-packages) jgart
2022-11-15 20:36 ` (
2022-11-16 14:19 ` Andreas Enge
2022-11-16 14:37 ` jgart
2022-11-16 14:44 ` Tobias Geerinckx-Rice
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).