I describe my distribution changes in RDF, and then use that RDF to generate the human-readable Changes files.
Despite rumours you might have heard to the contrary, RDF is not "based on XML", though it can be serialized as XML. Apparently Mark Pilgrim once mentioned that his partner had an XML file listing her shoe collection, but that this did not imply that her shoes were based on XML. :-)
RDF is an abstract data model which can be serialized in a variety of formats. It's a directed graph where edges are labelled with URIs, and nodes may either represent things (called "resources" in RDF terminology) or literal values (strings, numbers, dates, etc). Resources may also be labelled with a URI, but do not have to be.
Excuse my ASCII-art. The ( ) bits are supposed to be blank nodes (i.e. resources without a URI).
( ) ---[http://usefulinc.com/ns/doap#name]---> "Type-Tiny"
|
|
[http://usefulinc.com/ns/doap#release]
|
|
V
( ) ---[http://usefulinc.com/ns/doap#revision]---> "0.044"
But because drawing ASCII art can be tedious, we've come up with better ways to write down RDF. Here's the same data represented using Turtle:
@prefix doap: <http://usefulinc.com/ns/doap#>. :x doap:name "Type-Tiny". :x doap:release :y. :y doap:revision "0.044".
Or even:
@prefix doap: <http://usefulinc.com/ns/doap#>. [] doap:name "Type-Tiny"; doap:release [ doap:revision "0.044" ].
For each of my distributions, I include various RDF data such as the project name, contributors, repository, bug tracker, etc, using DOAP. DOAP is an RDF vocabulary which is used by Mozilla, the Python Package Index, and others.
I also use a few of my own extensions to DOAP for dealing with dependency data, changelogs, bug reports, etc.
Then, when I package the distribution, not only do I bundle the RDF data (example for Type-Tiny 0.044), I also use it to generate many of the standard distribution files (META.yml, Changes, CREDITS, etc).
My changeset extension for DOAP allows you to classify each change with one or more URIs. For example http://ontologi.es/doap-changeset#BackCompat or http://ontologi.es/doap-changeset#SecurityFix, but you can create your own URIs too, if these classes are not sufficient.
RDF is very, very extensible. That's kind of the main point of it. It's a data model for creating a web-scale database.
In reply to Re: A more machine readable and "machine actionable" Changes
by tobyink
in thread A more machine readable and "machine actionable" Changes
by sedusedan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |