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

Package binaries into VS Code extension #78

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

AmazingPP
Copy link
Contributor

@AmazingPP AmazingPP commented Jan 27, 2023

I package all binaries into vsix in release workflow. This way we don't have to download the binary anymore, which brings the bloat of vsix, but it's tolerable.

The solution mentioned in #77 does not apply to VS Code extensions, because users do not download optional dependencies when installing extensions.

Also, I remove extension part checkForUpdates setting, since users can control extension (including binaries) updates using the extensions.autoCheckUpdates and extensions.autoUpdate settings in VS Code.

Closes #77.

@AmazingPP
Copy link
Contributor Author

https://github.com/AmazingPP/zeek-language-server/releases/tag/prerelease

Here is a preview of the release workflow for review.

vscode/src/extension.ts Show resolved Hide resolved
vscode/src/extension.ts Outdated Show resolved Hide resolved
.github/workflows/release.yml Outdated Show resolved Hide resolved
with:
draft: false
files: |
vscode/*.vsix
Copy link
Owner

Choose a reason for hiding this comment

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

I really like this. I was surprised that the vsix file containing all platforms is smaller than downloading a single uncompressed executable, but I guess that makes sense.

In the past I created the vsix file for upload to the vscode marketplace offline, but this new build process makes that impossible. Would you mind looking into what it takes to do this upload from CI? I can create needed tokens etc.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added Personal Access Token (PAT) check and publish setp into release workflow.

I did a simple test on the Publish command (it can be built and packaged successfully and request me to provide a token). Because I didn't have a token, I didn't completely test whether Publish is completely correct.

@AmazingPP AmazingPP force-pushed the topic/amazingpp/binary-packaging branch from 8cf3a52 to 1908c14 Compare February 4, 2023 14:22
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.

Consider publishing binaries to npm registry as well
2 participants