Skip to content

Commit

Permalink
chore: fix rebuild-changelog action
Browse files Browse the repository at this point in the history
  • Loading branch information
nirinchev committed Jan 30, 2025
1 parent 3e86abc commit 183bf23
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/rebuild-changelog.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,15 +46,21 @@ jobs:
echo "# Change Log" > CHANGELOG.md
echo "" >> CHANGELOG.md
tags=$(gh api repos/mongodb-js/vscode/releases | jq -r .[].tag_name | grep -v internal | grep -v pre | grep -v beta)
tags=$(gh api --paginate repos/mongodb-js/vscode/releases --jq '.[].tag_name' | grep -v internal | grep -v pre | grep -v beta)
# NOTE: here the quotes around $tags are necessary
echo "$tags" | while read tagName; do
json=$(gh release view $tagName --json=name,publishedAt,url,body)
date=$(echo $json | jq -r .publishedAt | cut -f1 -dT)
if [[ -z "$date" ]]
then
echo "Skipping $tagName because it's not published yet"
continue
fi
url=$(echo $json | jq -r .url)
name=$(echo $json | jq -r .name)
date=$(echo $json | jq -r .publishedAt | cut -f1 -dT)
body=$(echo $json | jq -r .body)
echo "## [$name]($url) - $date" >> CHANGELOG.md
echo "" >> CHANGELOG.md
Expand Down

0 comments on commit 183bf23

Please sign in to comment.