Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Website: Add download statistics page #588

Open
damienalexandre opened this issue Nov 29, 2024 · 0 comments
Open

Website: Add download statistics page #588

damienalexandre opened this issue Nov 29, 2024 · 0 comments

Comments

@damienalexandre
Copy link
Member

Just for fun we could add a download stats page on the website.

A bit like https://symfony.com/stats/downloads

Based on Github API we can extract the download for each type of releases.

$ gh api /repos/jolicode/castor/releases | jq ".[] | {name: .name, assets: [.assets[] | {name: .name, count: .download_count}]}"

This API gives for example, for each release:

{
  "name": "Release v0.18.2",
  "assets": [
    {
      "name": "castor.linux-arm64.phar",
      "count": 3
    },
    {
      "name": "castor.darwin-amd64",
      "count": 9
    },
    {
      "name": "castor.windows-amd64.phar",
      "count": 25
    },
    {
      "name": "castor.darwin-amd64.phar",
      "count": 33
    },
    {
      "name": "castor.darwin-arm64.phar",
      "count": 86
    },
    {
      "name": "castor.linux-amd64",
      "count": 3940
    },
    {
      "name": "castor.linux-amd64.phar",
      "count": 10928
    }
...
@damienalexandre damienalexandre changed the title Add download statistics page Website: Add download statistics page Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant