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

Publish extension via GH action on GH release #542

Merged
merged 1 commit into from
Sep 19, 2024

Conversation

juliasilge
Copy link
Collaborator

This PR sets up infrastructure to publish the extension to the two marketplaces (OpenVSX and the Visual Studio Marketplace) via GH action via doing a GH release. I'll make a few notes on the PR for us to use for discussion moving forward.

Copy link
Collaborator Author

@juliasilge juliasilge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This action builds the extension one time and then publishes exactly the same file to both OpenVSX and the Microsoft marketplace. There are alternative approaches if we have a reason for another approach.

Comment on lines +5 to +7
release:
types:
- published
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I set this up to use a release but alternatively we could use a tag in the way the Shiny team does.

- name: Publish to Open VSX Registry
uses: HaaLeo/publish-vscode-extension@v1
with:
pat: ${{ secrets.OPEN_VSX_TOKEN }}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the first of two tokens we will need added to the repo secrets to make this work.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JJ added this a couple of days ago to this repo's secrets. ✅

- name: Publish to Visual Studio Marketplace
uses: HaaLeo/publish-vscode-extension@v1
with:
pat: ${{ secrets.VS_MARKETPLACE_TOKEN }}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the second of two tokens we will need added to the repo secrets to make this work.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just added this to this repo's secrets, after being added as a publisher for the Quarto extension. I made a token that expires after 90 days FYI so we will need to replace it at that time. If we feel comfortable, next time I can make one that never expires.

@cscheid
Copy link
Contributor

cscheid commented Sep 19, 2024

This all looks good to me!

@juliasilge juliasilge merged commit 09bb967 into main Sep 19, 2024
2 checks passed
@juliasilge juliasilge deleted the publish-extension-with-gh-release branch September 19, 2024 23:06
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

Successfully merging this pull request may close these issues.

2 participants