Am Donnerstag, den 29.03.2018, 14:08 +0200 schrieb Andreas Pretzsch:
> On Do, 2018-03-29 at 07:29 +0000, Denis OSTERLAND wrote:
> > 
> > +++ b/scripts/lib/ptxd_make_license_csv.sh
> > @@ -0,0 +1,16 @@
> > +#! /bin/bash
> > +#
> > +# Copyright (C) 2017 by Denis Osterland <denis.osterl...@diehl.com>
> > +#
> > +
> > +ptxd_make_license_csv() {
> > +       declare -A pkg_license_flags
> > +       ptxd_make_world_license_init || return
> > +
> > +       if [ "${pkg_section}" != "ignore" ]
> > +               then
> > +               echo "${pkg_label};${pkg_version};${pkg_section};
> > ${pkg_license};${pkg_url}" > ${pkg_license_dir}/report.csv
> > +               fi
> > +}
> > +export -f ptxd_make_license_csv 
> Extending the field list by section is a good point, thanks. Will do.
> 
> But I would refrain from including the URL (for now), simply as it will
> include all sorts of characters, which then will require proper
> escaping. And in 20+ years, I've seen way too many broken parsers (and
> escapers)...
> Beside, the key point of the CSV list (to me / customers) is to have a
> diff'able list of included packages (which ones, version, license),
> beside the full fledged report. To see if one needs to look into
> something. So URL is nice, but not mandatory.
> 
> Last, about the CSV separator, I chose | out of experience, avoiding
> most collisions. Both , and ; show up often in text and even version
> tags. Yes, they are marked as string with "", but back to "broken
> parsers"...
> 
> So I still tend to a CSV output like:
> 
> "name"|"version"|"section"|"licenses"|"flags"
> "somepackage"|"1.2.3"|"osi-conform"|"Apache-2.0"|"attribution"
> [...]
> 
> 
> Denis, what do you think ?
You are right, URL tend to be brittle.
We use it as input for an overview page on embedded web server.
This will need some refactoring.
By the way, is it possible depend on your csv report from make?
I guess I will need to add some wrapper target to call sh function.

Regards Denis
> Michael, any experience/opinion on this ?
> 
> Best regards,
>   Andreas
> 
Diehl AKO Stiftung & Co. KG, Pfannerstraße 75-83, 88239 Wangen im Allgäu
Bereichsvorstand: Dr.-Ing. Michael Siedentop (Sprecher), Josef Fellner 
(Mitglied)
Sitz der Gesellschaft: Wangen i.A. – Registergericht: Amtsgericht Ulm HRA 
620609 – Persönlich haftende Gesellschafterin: Diehl Verwaltungs-Stiftung – 
Sitz: Nürnberg – Registergericht: Amtsgericht Nürnberg HRA 11756 –
Vorstand: Dr.-Ing. E.h. Thomas Diehl (†) (Vorsitzender), Herr 
Dipl.-Wirtsch.-Ing. Wolfgang Weggen (stellvertretender Vorsitzender), 
Dipl.-Kfm. Claus Günther, Dipl.-Kfm. Frank Gutzeit, Dr.-Ing. Heinrich Schunk, 
Dr.-Ing. Michael Siedentop , Dipl.-Kfm. Dr.-Ing. Martin Sommer, Dipl.-Ing. (FH) 
Rainer von Borstel, Vorsitzender des Aufsichtsrates: Dr. Klaus Maier
___________________________________________________________________________________________________
Der Inhalt der vorstehenden E-Mail ist nicht rechtlich bindend. Diese E-Mail 
enthaelt vertrauliche und/oder rechtlich geschuetzte Informationen.
Informieren Sie uns bitte, wenn Sie diese E-Mail faelschlicherweise erhalten 
haben. Bitte loeschen Sie in diesem Fall die Nachricht. Jede unerlaubte Form 
der Reproduktion, Bekanntgabe, Aenderung, Verteilung und/oder Publikation 
dieser E-Mail ist strengstens untersagt.
The contents of the above mentioned e-mail is not legally binding. This e-mail 
contains confidential and/or legally protected information. Please inform us if 
you have received this e-mail by mistake and delete it in such a case. Each 
unauthorized reproduction, disclosure, alteration, distribution and/or 
publication of this e-mail is strictly prohibited.
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de

Reply via email to