Skip to content

Github CI visx extension build #4

Github CI visx extension build

Github CI visx extension build #4

Workflow file for this run

name: Build VSIX
on:
push:
pull_request:
workflow_dispatch:
jobs:
build-vsix:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- name: Install dependencies
run: npm ci
- name: Compile extension
run: npm run compile
- name: Set VSIX output name
run: |
if [ "${GITHUB_REF_TYPE}" = "tag" ]; then
echo "VSIX_PATH=open-command-${GITHUB_REF_NAME}.vsix" >> "$GITHUB_ENV"
else
echo "VSIX_PATH=open-command.vsix" >> "$GITHUB_ENV"
fi
- name: Package VSIX
run: npm run package:vsix -- --out "${VSIX_PATH}"
- name: Upload VSIX artifact
uses: actions/upload-artifact@v4
with:
name: open-command-vsix
path: ${{ env.VSIX_PATH }}
if-no-files-found: error
- name: Publish VSIX to GitHub Releases
if: github.ref_type == 'tag'
uses: softprops/action-gh-release@v2
with:
files: ${{ env.VSIX_PATH }}
fail_on_unmatched_files: true
generate_release_notes: true