I’m developing omeka-cli and one of its features is to download plugins from omeka.org. The solution I used for this is to parse the HTML of http://omeka.org/add-ons/plugins/ and plugins page like http://omeka.org/add-ons/plugins/simple-pages/.
I wonder if there is a better solution, like a REST API for example, that would allow to also retrieve data from plugin.ini (or theme.ini) file without having to download the zip file.
Another problem with parsing omeka.org is that it lacks one important info : the plugin’s directory name, which is the unique identifier of the plugin. On omeka.org we have the archive’s filename and the name of the Wordpress post, but they do not always match with the directory name in the zip file.
The only alternative I could come up with is to download all zip files, extract the needed info into a big JSON file and publish it online so that omeka-cli can use it.
An example of that is here : https://github.com/jajm/omeka-addons-index
It is updated automatically every night thanks to Travis CI, but that means every add-on page is fetched once a day (only new add-ons are downloaded), and omeka-cli will depend on a file on Github to be able to download plugins from omeka.org, and I would like to avoid that.
Is there any other solution ?