Skip to content

release: Add deployment task #2

release: Add deployment task

release: Add deployment task #2

Workflow file for this run

name: Build, Lint, Test and possibly release
on:
push:
branches:
- "*"
pull_request:
branches:
- main
release:
types:
- created
jobs:
build-lint-test-release:
name: Node
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout Source
uses: actions/checkout@v2
- name: Install Node 16
uses: actions/setup-node@v1
with:
node-version: 16
- name: Install Dependencies
run: npm ci
- name: Run Linter
run: npm run lint
- name: Build Code
run: npm run compile
- name: Test server
working-directory: server
run: npm run test
- name: Publish
if: success() && startsWith(github.ref, 'refs/tags/') && matrix.os == 'ubuntu-latest'
run: npm run deploy
env:
VSCE_PAT: ${{ secrets.VSCE_PAT }}
OVSX_PAT: ${{ secrets.OVSX_PAT }}
# deactive as does not work on CI
# - name: Run Unit Tests
# run: xvfb-run -a npm run test