GNU bug report logs - #76662
[PATCH 0/1] Add guix AppStream catalog generation

Previous Next

Package: guix-patches;

Reported by: Noé Lopez <noe <at> xn--no-cja.eu>

Date: Sat, 1 Mar 2025 16:46:02 UTC

Severity: normal

Tags: patch

Merged with 76661

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Noé Lopez <noe <at> xn--no-cja.eu>
To: guix-patches <at> gnu.org
Cc: Noé Lopez <noelopez <at> free.fr>
Subject: [PATCH 0/1] Add guix AppStream catalog generation
Date: Sat,  1 Mar 2025 17:44:45 +0100
From: Noé Lopez <noelopez <at> free.fr>

Hi,

This patch adds a new “guix appstream” command that generates an AppStream
catalog out of all packages contained in the current guix (channels included).

This patch is part of my work on PackageKit integration and is needed for
Gnome Software and Discover to recognise packages.  The installation of the
xml file is intentionaly left out for now, but I imagine it could be done
using a (home) service.  Similarly, the xml file presents some shortcomings:

– It contains too many packages, and does not take into account the different
  package outputs.

– It does not respect packages’ metainfo files or desktop entries, as you need
  a built package for that.  This means no icons, wrong rDNS ids, and only the
  metainfo guix knows.

It doesn’t need to be merged in this version but I am posting to get some
reviews on what I currently have :)

If you want to try out the command, the resulting xml file should be placed in
/var/lib/swcatalog/xml/ and can be tested using appstreamcli:

noe <at> lignux ~/src/guix-appstream [env]$ ./pre-inst-env guix appstream
[…]
Created guix-1.4.0-31.121e96d.xml with 33125 packages
noe <at> lignux ~/src/guix-appstream [env]$ sudo cp guix-1.4.0-31.121e96d.xml /var/lib/swcatalog/xml/
noe <at> lignux ~/src/guix-appstream [env]$ guix shell appstream -- appstreamcli search openttd
Identifier: openttd [desktop-application]
Name: openttd
Summary: Transportation economics simulator game
Package: openttd
Homepage: https://www.openttd.org/
\---
Identifier: catcodec [desktop-application]
Name: catcodec
Summary: Encode/decode OpenTTD sounds
Package: catcodec
Homepage: https://dev.openttdcoop.org/projects/catcodec

Noé Lopez (1):
  guix appstream: New script.

 Makefile.am                |   1 +
 guix/import/utils.scm      |  14 +++++
 guix/scripts/appstream.scm | 125 +++++++++++++++++++++++++++++++++++++
 3 files changed, 140 insertions(+)
 create mode 100644 guix/scripts/appstream.scm


base-commit: d1e3c41abdda9f8e9f1283376feb853670393793
-- 
2.48.1





This bug report was last modified 111 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.