Commit Graph

3 Commits

Author SHA1 Message Date
cc2e1a8729 fix(badge/downloads): fix issues with total download counts
Excluded patterns had a bug where they basically did not work. This
means total downloads were inflated by also counting downloads for all
sha256 files.

Also the first 1000 limit when listing repository releases seems to no
loner be a thing, so we can iterate over all pages.

And finally, implement a caching mechanism so we can keep counting
releases in case they are removed, or the first 1000 releases limit is
enabled again in GitHub's API.
2023-11-24 20:35:36 +00:00
86ea221039 fix(downloads): only 1000 latest releases available via API
Requests for releases beyond the latest 1000 yields the following error
from the API:

    422 Only the first 1000 results are available
2023-07-31 19:46:31 +01:00
9afd4f24d3 feat(meta/downloads): add basic meta updater written in Go
It currently only supports outputting a shields.io JSON badge for the
total number of downloads, calculated by iterating over all pages of
GitHub Releases and counting download totals.

Shields.io's own release downloads badge only checks downloads counts
from the first page (100 releases).
2021-11-11 01:29:57 +00:00