#1080036 teensy-loader-cli: Add Appstream metainfo announcing HW support

Package:
teensy-loader-cli
Source:
teensy-loader-cli
Description:
load and run programs onto your Teensy micro controller
Submitter:
Petter Reinholdtsen
Date:
2024-08-31 13:51:02 UTC
Severity:
normal
Tags:
#1080036#5
Date:
2024-08-29 21:15:58 UTC
From:
To:
Here is a draft patch to add Appstream metainfo XML announcing the
hardware handled by this package.  The USB ID were fetched from one
listed in debian/49-teensy.rules.  This should fix the
'appstream-metadata-missing-modalias-provide' lintian warning.

Including this information in the package will ensure programs mapping
hardware to packages using Appstream information, like the isenkram
package, will know that this package is useful on machines where the
hardware is discovered.

The appstream metadata file can be checked using this command after
package build:

  appstreamcli validate-tree  --no-net --explain debian/teensy-loader-cli

diff --git a/debian/install b/debian/install
index ef9bd71..ccf34c8 100644
--- a/debian/install
+++ b/debian/install
@@ -1,2 +1,3 @@
 teensy_loader_cli /usr/bin/
 debian/49-teensy.rules /lib/udev/rules.d/
+com.pjrc.teensy.loader_cli.metainfo.xml usr/share/metainfo
diff --git a/debian/lintian-overrides b/debian/lintian-overrides
deleted file mode 100644
index 41871cd..0000000
--- a/debian/lintian-overrides
+++ /dev/null
@@ -1,6 +0,0 @@
-teensy-loader-cli: appstream-metadata-missing-modalias-provide
-# to silence Lintian warning about lib/udev/rules.d/49-teensy.rules
-# Frankly:
-#   I think the warning is bogus
-# More Frankly:
-#   I don't understand https://wiki.debian.org/AppStream/Guidelines#Announcing_supported_hardware
diff --git a/debian/patches/1000-appstream-metainfo.patch b/debian/patches/1000-appstream-metainfo.patch
new file mode 100644
index 0000000..3b7556d
--- /dev/null
+++ b/debian/patches/1000-appstream-metainfo.patch
@@ -0,0 +1,29 @@
+Description: Added AppStream metainfo XML with hardware provide info.
+ This allow isenkram to propose this package when the relevant hardware is
+ present.
+Author: Petter Reinholdtsen
+Forwarded: no
+Last-Update: 2024-08-29
+---
+Index: teensy-loader-cli-salsa/com.pjrc.teensy.loader_cli.metainfo.xml
+===================================================================
+--- /dev/null  1970-01-01 00:00:00.000000000 +0000
++++ teensy-loader-cli-salsa/com.pjrc.teensy.loader_cli.metainfo.xml    2024-08-29 23:07:17.755293371 +0200
+@@ -0,0 +1,17 @@
++<?xml version="1.0" encoding="UTF-8"?>
++<component>
++  <id>com.pjrc.teensy.loader_cli</id>
++  <metadata_license>MIT</metadata_license>
++  <name>teensy-loader-cli</name>
++  <summary>load and run programs onto your Teensy micro controller</summary>
++  <description>
++    <p>The teensy loader cli is a command-line alternative to the
++    graphical teensy loader which is included with Teensyduino. The
++    cli version is preferred by advanced users who want to automate
++    programming, typically from within a Makefile or similar.</p>
++  </description>
++  <url type="homepage">https://www.pjrc.com/teensy/loader_cli.html</url>
++  <provides>
++    <modalias>usb:v16C0p04[789ABCD]?d*</modalias>
++  </provides>
++</component>
diff --git a/debian/patches/series b/debian/patches/series
index a6791a4..42e8b1a 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1 @@
-# currently no patches for Debian
+1000-appstream-metainfo.patch

#1080036#10
Date:
2024-08-31 13:27:27 UTC
From:
To:
Acknowlegde.

Please elaborate on 'draft'  in "Here is draft patch".

Thing I would like known:  How long to wait for a more final version?


Do know that I'm happy with a response like:

  Yes, it will be the best version for the upcoming months (or upcoming
  years).  Consider 'draft' in "a draft patch" as politeness form.


Regards
Geert Stappers
One of the previous uploaders of teensy-loader-cli

#1080036#15
Date:
2024-08-31 13:46:23 UTC
From:
To:
[Geert Stappers]

Ah, sorry about that.  I considered it a draft from my hands, and hope
someone who know the package better can have a look and see if the XML
file should have a better description, a different or extended set of
hardware IDs (aka <modalias> entries) or in any other way be improved.
In other words, it is as good as I can get it, but I am sure it can be
improved. :)

No need to wait. :)