help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Most used and least used build-system in Guix packages


From: Maxim Cournoyer
Subject: Re: Most used and least used build-system in Guix packages
Date: Wed, 12 Apr 2023 21:55:39 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux)

Hello,

Rodrigo Morales <moralesrodrigo1100@gmail.com> writes:

> Table of Contents
> _________________
>
> 1. TL; DR
> 2. My findings
> 3. The question
>
>
> 1 TL; DR
> ========
>
>   Today, I was wondering what the most used build system and the least
>   one are. The most used build system is `gnu-build-system'. The least
>   used build system is `dub-build-system'. Here's how I found that out.
>
>
> 2 My findings
> =============
>
>   ,----
>   | (car %load-path)
>   `----
>
>   ,----
>   |
> /gnu/store/zc7dzsd10dd3pw60hircphz4vh1wlki0-guix-module-union/share/guile/site/3.0
>   `----
>
>   ,----
>   |
> dir="/gnu/store/zc7dzsd10dd3pw60hircphz4vh1wlki0-guix-module-union/share/guile/site/3.0"
>   | path="$dir/gnu/packages"
>   | grep -hREo '[a-zo-]+-build-system' $path | sort | uniq -c | sort -nr
>   `----
>
>   ,----
>   | 3893 gnu-build-system
>   | 2717 python-build-system

[...]


> 3 The question
> ==============
>
>   Does anyone know if there's a more accurate way of finding out this
>   information? I'm asking because my method also counts build systems
>   that are mentioned in comments. For example, if a file contains
>   comments that mention build systems, they are also counted.

Guix provides an API, so you could use it from the comfort of the 'guix
repl' REPL to query it, using fold-packages.

The following repo will surely provide some clues as to how to do that;
the following is an example querying all the packages that make use of
the emacs-build-system [0]

[0]  
https://notabug.org/apteryx/guix-api-examples/src/master/emacs-packages-manifest.scm

Have fun!

-- 
Thanks,
Maxim



reply via email to

[Prev in Thread] Current Thread [Next in Thread]