Skip to content

feat: update GitHub Actions workflow to publish VS Code extension on merged PRs#11

Merged
kasuken merged 1 commit into
mainfrom
githubaction
Sep 8, 2025
Merged

feat: update GitHub Actions workflow to publish VS Code extension on merged PRs#11
kasuken merged 1 commit into
mainfrom
githubaction

Conversation

@kasuken
Copy link
Copy Markdown
Owner

@kasuken kasuken commented Sep 8, 2025

  • Changed trigger from push to pull_request for the main branch.
  • Added condition to ensure the job runs only on merged PRs.
  • Updated npm install command from npm ci to npm install.
  • Added step to upload VSIX artifact after packaging.
  • Adjusted environment variable for VSCE token to use VSCE_PAT.

…merged PRs

- Changed trigger from push to pull_request for the main branch.
- Added condition to ensure the job runs only on merged PRs.
- Updated npm install command from `npm ci` to `npm install`.
- Added step to upload VSIX artifact after packaging.
- Adjusted environment variable for VSCE token to use VSCE_PAT.
Copilot AI review requested due to automatic review settings September 8, 2025 15:06
@kasuken kasuken merged commit f0b898d into main Sep 8, 2025
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Updates the GitHub Actions workflow to publish the VS Code extension specifically when PRs are merged into the main branch, rather than on every push. This change provides better control over when the extension is published to the marketplace.

Key changes:

  • Modified trigger from push events to merged pull request events
  • Added VSIX artifact upload for better build traceability
  • Updated environment variable configuration for VSCE authentication

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.


- name: Install dependencies
run: npm ci
run: npm install
Copy link

Copilot AI Sep 8, 2025

Choose a reason for hiding this comment

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

Changed from npm ci to npm install without justification. npm ci is preferred in CI environments as it performs faster, reliable, reproducible builds by installing directly from package-lock.json and fails if dependencies don't match the lock file.

Suggested change
run: npm install
run: npm ci

Copilot uses AI. Check for mistakes.
Comment on lines +46 to +47
# vsce reads token from VSCE_PAT; no need to pass --pat explicitly
vsce publish No newline at end of file
Copy link

Copilot AI Sep 8, 2025

Choose a reason for hiding this comment

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

[nitpick] The comment states that vsce reads the token from VSCE_PAT, but this behavior should be verified. The previous approach using --pat was explicit and clear. Consider keeping the explicit token passing for better clarity and reliability.

Suggested change
# vsce reads token from VSCE_PAT; no need to pass --pat explicitly
vsce publish
# Explicitly pass the token using --pat for clarity and reliability
vsce publish --pat $VSCE_PAT

Copilot uses AI. Check for mistakes.
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