web API for most recent build

Website, builds, or other suggestions.
Post Reply
stib
Posts: 5
Joined: Wed Dec 03, 2014 7:49 am

web API for most recent build

Post by stib »

It would be great if there was an API for your website that made it easy to automate the process of finding the most recent build and downloading it.

I'm kludging together a script that scrapes the info from the site, but it would be a lot easier and more reliable if there was something that returned some JSON or XML with the build ID of the current version, and the download address for each flavour of build.

The RSS feed is close, but you still have to extract the build target and download address from the text body. You could add additional key/value pairs in the feed xml eg

Code: Select all

<Win32Static>http://ffmpeg.zeranoe.com/builds/win32/static/ffmpeg-20150726-git-b16b8c8-win32-static.7z</Win32static>
<Win32Shared>http://ffmpeg.zeranoe.com/builds/win32/shared/ffmpeg-20150726-git-b16b8c8-win32-shared.7z</Win32static>
etc… and that would work perfectly


Thanks for the good work


stib
Posts: 5
Joined: Wed Dec 03, 2014 7:49 am

Re: web API for most recent build

Post by stib »

The only problem is that URL doesn't return the date of the last build. If I write something that checks whether there's a new build, it needs to know the date it was built. I'm suggesting a function that simply returns the date and location of each build, so a URL like

Code: Select all

http://ffmpeg.zeranoe.com/latestbuild&arch=64&type=static
returns some XML like:

Code: Select all

<latest build>ffmpeg-20150729-git-9ec17e4</latest build>
<build date>28-Jul-2015 22:18</build date>
<address>http://ffmpeg.zeranoe.com/builds/win64/static/ffmpeg-20150729-git-9ec17e4-win64-static.7z</address>
(or the equivalent in JSON)

svnpenn
Posts: 263
Joined: Tue Nov 01, 2011 12:19 am

Re: web API for most recent build

Post by svnpenn »

Stop trying to reinvent the wheel.

Code: Select all

curl --time-cond 20150729 <url>

stib
Posts: 5
Joined: Wed Dec 03, 2014 7:49 am

Re: web API for most recent build

Post by stib »

Awesome. One day I will put on a pot of coffee, sit down and actually read all of the curl man page.

Post Reply