Skip to content

Commit

Permalink
Add GitHub action to test and build extension
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkusEllyton committed Oct 25, 2024
1 parent dc9281b commit b3b2d3a
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/package-vsix.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Build and Test VS Code Extension

on:
push:
branches:
- main
pull_request:

jobs:
build-and-test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
node-version: [20]

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}

- name: Install dependencies
run: npm install

- name: Run tests
run: npm test:unit

- name: Build the extension
run: npx vsce package

- name: Upload .vsix artifact
uses: actions/upload-artifact@v3
with:
name: vscode-extension-${{ matrix.os }}
path: '*.vsix'

0 comments on commit b3b2d3a

Please sign in to comment.