Grafana: use GitHub releases

This commit is contained in:
Steffen Lange 2022-06-09 16:23:31 +02:00
parent 2fce0caefa
commit 02cfb3588d

View file

@ -5,8 +5,8 @@ class Grafana extends PatchBase {
parent::__construct('Grafana Labs', 'Grafana', 'https://grafana.com/grafana/download');
}
function check() : bool {
if ($this->fetch('https://grafana.com/grafana/download'))
return $this->parse('/selected="" value="([\d\.]+)"/');
if ($this->fetch_json('https://api.github.com/repos/grafana/grafana/releases/latest'))
return $this->parse_json('tag_name');
return false;
}
}