Create a CHANGELOG.md before publishing extension update#810
Conversation
|
|
||
| - name: Create CHANGELOG.md | ||
| run: | | ||
| RELEASE_NOTES=$(curl -L https://api.github.com/repos/Shopify/vscode-ruby-lsp/releases) |
There was a problem hiding this comment.
Instead of using curl, let's use github-script.
We can fetch only the latest release directly and I'm sure the release's ID or tag must be present in the action's context object. That way we don't need to use curl or jq.
There was a problem hiding this comment.
Yes we can but doing that CHANGELOG will include only lastest release information. Is it the expected behavior?
There was a problem hiding this comment.
That's a good point. It probably makes more sense to include everything. Let's still use github-script if possible though.
There was a problem hiding this comment.
Done, and tested with ci.yml workflow again: https://github.com/snutij/vscode-ruby-lsp/actions/runs/6364070663/job/17280102315
062a375 to
ea94ec5
Compare
vinistock
left a comment
There was a problem hiding this comment.
Very nice. Thank you for putting this together and testing it!
Motivation
Closes Shopify/ruby-lsp#1645
The need is to create a
CHANGELOG.md(without manual intervention) packaged into the extension publish.Implementation
#before the tag to make a clear separation in the markdown between each releaseCHANGELOG.mdat the root level as required by the specificationAutomated Tests
Impossible as I can't publish it myself.
Manual Tests
I did a test, adding this code in the
ci.ymlworkflow to check that everything goes as expected on push on my fork.Result is available here: https://github.com/snutij/vscode-ruby-lsp/actions/runs/6344046810/job/17233282072
lsoutput show the root level with theCHANGELOG.mdCHANGELOG.mdshow the output well formattedNote: we can see before each release note content this
<!-- Release notes generated using configuration in .github/release.yml at main -->but we don't care as this is a comment it should not be displayed into vscode extension changelog tab.I'll not copy-past output here, because it will link this PR to all PR already merged 😄