Created
September 18, 2021 22:07
-
-
Save danburzo/f82d757e870054c1c714f9527980ddb8 to your computer and use it in GitHub Desktop.
Release notes for npm package
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
# ------------------------------------------- | |
# List the release notes of any npm package, | |
# as long as it publishes releases on GitHub. | |
# | |
# Usage: releasenotes d3 | |
# ------------------------------------------- | |
function releasenotes() { | |
URL=$( | |
npm view $1 repository.url |\ | |
xargs npx parse-github-url |\ | |
jq -r '.repository' | |
); | |
gh release list --repo $URL |\ | |
cut -f1 |\ | |
xargs -I{} gh release --repo $URL view {}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment