Commit Graph

7 Commits

Author SHA1 Message Date
Simon Tournier 092db20bcf
hydra: build-package-metadata: Add boolean for Git submodules in sources.json.
This format had been discussed in
<https://gitlab.softwareheritage.org/swh/devel/swh-loader-git/-/issues/4751#note_150607>

* hydra/build-package-metadata.scm (origin->json)[resolve]: Add the keyword
'submodule' when the Git reference is recursive.

Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
2023-10-17 14:27:35 +02:00
Ludovic Courtès 58bd4453c8
hydra: build-package-metadata: Produce ‘variable_name’ field when possible.
* hydra/build-package-metadata.scm (package-variable-name): New procedure.
(package->json): Use it to produce ‘variable_name’ field.
2023-10-09 14:27:06 +02:00
Ludovic Courtès 1123fd81ce
hydra: build-package-metadata: Compress JSON files.
* hydra/build-package-metadata.scm (write-json): Use
‘call-with-gzip-output-port’.
(main): Append “.gz” to JSON file names.
* hydra/modules/sysadmin/nginx.scm (guix.gnu.org-other-locations): Add
“gzip_static” and “gunzip” directives on /packages.json and
/sources.json.
2023-10-09 10:57:31 +02:00
Simon Tournier 24249ac02e
hydra: build-package-metadata: Update fields in sources.json.
This format had been discussed in
<https://gitlab.softwareheritage.org/swh/infra/sysadm-environment/-/issues/4868>.

* hydra/build-package-metadata.scm (origin->json)[resolve]: Add the fields
'outputHashAlgo' and 'outputHashMode'.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2023-05-12 13:45:01 +02:00
Ludovic Courtès b7af47ceb6
build-package-metadata: Include content-addressed URLs for tarballs.
Suggested by Simon Tournier <zimon.toutoune@gmail.com> in
<https://lists.gnu.org/archive/html/guix-devel/2023-04/msg00029.html>.

* hydra/build-package-metadata.scm (%content-addressed-mirrors): New variable.
(origin->json)[resolve]: Add 'hash' parameter; when true, add a list of
content-addressed URLs.
Update caller.
2023-04-25 14:50:58 +02:00
Ludovic Courtès d181954dc6
hydra: build-package-metadata: Make files world-readable.
* hydra/build-package-metadata.scm (write-json): Add 'chmod' call.
2023-01-04 22:55:32 +01:00
Ludovic Courtès 318db3eedf
hydra: Add 'build-package-metadata.scm' script.
This program produces the 'packages.json' and 'sources.json' files that
are published at https://guix.gnu.org.

So far those files were built as part of the web site's build process,
via Haunt.  This script is adapted from the (apps packages builder)
module of the web site.

* hydra/build-package-metadata.scm: New file.
2023-01-04 22:06:04 +01:00