Update lockrattler appcast (#65220)

* Update lockrattler appcast

Experimental idea: Lockrattler is one of these with a problematic appcast. Its too noisy to observe for changes (wordpress!) and also contains a lot of other version numbers that make a 'contains' check less than ideal.

The good news is that this app contains a 'check for updates' function that has been recently released.
The bad news is that the configuration file ( https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist ) is used for a few dozen apps and therefore just as noisy and contains just as many unrelated versions.

I've been toying with the idea of using a CGI to extract just the portions we need from the file.

The CGI ( https://gist.github.com/core-code/0def150fa245b333fb0541f9f999b040#file-extract_text_split-cgi ) takes a URL to process as parameter as well as a JSON array containing the 'split points'. Configured in the right way it just spits out the version number we need. 
I think CGIs like these could also be useful if we need special headers ( ubiquiti-unifi-controller  ), cookies or a POST request to get the information we need.
Ideally all this (including our current CGIs that get the filename or redirect) would be implemented as parameters on the appcast stanza, defining what to do, instead of defining a special way to do this (by calling our CGI), but i don't see that happening anytime soon.

Feel free to reject this PR - i don't think its strictly necessary in this case, and this might also not be the most popular cask anyway. Also, I have no problem implementing a list of 'override' appcasts on our end to help keep casks like this one up-to-date if you feel like using this 'extract_text' CGI in the appcast of the caskfile is not a good idea.

* Update lockrattler.rb

* Update lockrattler.rb
This commit is contained in:
CoreCode 2019-06-24 17:22:04 +02:00 committed by Vítor Galvão
parent 6b7fe7cb1e
commit 6ab11d337a
1 changed files with 1 additions and 1 deletions

View File

@ -4,7 +4,7 @@ cask 'lockrattler' do
# eclecticlightdotcom.files.wordpress.com was verified as official when first introduced to the cask
url "https://eclecticlightdotcom.files.wordpress.com/#{version.after_comma.major}/#{version.after_comma.minor}/lockrattler#{version.before_comma.no_dots}.zip"
appcast 'https://eclecticlight.co/lockrattler-systhist/'
appcast 'https://www.macupdater.net/cgi-bin/extract_text/extract_text_split.cgi?splitters=\[\{%22s%22:%22LockRattler%22,%22i%22:1\},\{%22s%22:%22Version%22,%22i%22:1\},\{%22s%22:%22dict%22,%22i%22:0\}\]&url=https://raw.githubusercontent.com/hoakleyelc/updates/master/eclecticapps.plist'
name 'Lock Rattler'
homepage 'https://eclecticlight.co/'