ci: create release of vscode extension#4765
Merged
Conversation
4ccf83d to
3517c57
Compare
Comment on lines
+8
to
+44
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout repository | ||
| uses: actions/checkout@v4 | ||
| - name: Setup Node.js | ||
| uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: '20' | ||
| - name: Install pnpm | ||
| uses: pnpm/action-setup@v2 | ||
| with: | ||
| version: 10 | ||
| - name: Install dependencies | ||
| run: pnpm install --frozen-lockfile | ||
| - name: Extract version from tag | ||
| id: extract_version | ||
| run: | | ||
| VERSION=${GITHUB_REF#refs/tags/vscode@v} | ||
| echo "VERSION=$VERSION" >> $GITHUB_OUTPUT | ||
| - name: Update package.json version | ||
| working-directory: vscode/extension | ||
| run: | | ||
| npm version ${{ steps.extract_version.outputs.VERSION }} --no-git-tag-version | ||
| - name: Install dependencies | ||
| working-directory: vscode/extension | ||
| run: pnpm install | ||
| - name: Run CI | ||
| run: pnpm run ci | ||
| - name: Build extension | ||
| working-directory: vscode/extension | ||
| run: pnpm run vscode:package | ||
| - name: Package extension | ||
| working-directory: vscode/extension | ||
| run: | | ||
| pnpm run vscode:package | ||
| - name: Upload extension to Marketplace | ||
| working-directory: vscode/extension | ||
| run: | | ||
| pnpx vsce publish --packagePath sqlmesh-${{ steps.extract_version.outputs.VERSION }}.vsix | ||
| env: | ||
| VSCE_PAT: ${{ secrets.VSCE_PAT }} |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
This autofix suggestion was applied.
Show autofix suggestion
Hide autofix suggestion
This autofix suggestion was applied.
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI 10 months ago
To fix the issue, add a permissions block to the workflow. This block should specify the minimal permissions required for the workflow to function correctly. Based on the operations performed in the workflow, the following permissions are recommended:
contents: readfor accessing repository contents.packages: writefor publishing the extension to the Marketplace.
The permissions block should be added at the root level of the workflow to apply to all jobs, as no job-specific permissions are defined.
Suggested changeset
1
.github/workflows/release_extension.yaml
| @@ -5,2 +5,5 @@ | ||
| - 'vscode@v*' | ||
| permissions: | ||
| contents: read | ||
| packages: write | ||
| jobs: |
Copilot is powered by AI and may make mistakes. Always verify output.
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a new GitHub Actions workflow to automate the release process for the VSCode extension.
- Adds a workflow triggered by push tags matching the pattern "vscode@v*".
- Implements steps for checking out code, setting up Node.js, installing dependencies, extracting version, updating package.json, building, packaging, and uploading the extension.
izeigerman
reviewed
Jun 24, 2025
5e26dbd to
33aff98
Compare
33aff98 to
5c97517
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.