Created
July 3, 2018 13:27
-
-
Save Southclaws/65ae09c6fcd1314d1f86410c845684d5 to your computer and use it in GitHub Desktop.
Count total downloads from GitHub releases using the GitHub API v3 and a simple jq expression
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
# https://jqplay.org/s/CpDPlGueMM | |
# usage: `github-release-downloads.sh Username/Repository` | |
curl -s https://api.github.com/repos/$1/releases | | |
jq '[.[].assets | .[].download_count] | add' - |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
comment.