Skip to content

adjust release action #12

adjust release action

adjust release action #12

Workflow file for this run

name: Create Github Release
on:
push:
tags:
- 'v*' # Run when a version tag (e.g., v1.0.0) is pushed
jobs:
test:
if: github.ref_type == 'tag'
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version: [18.x, 20.x]
os: [ubuntu-latest, windows-latest, macos-latest]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
- run: npm ci
- run: npm run compile --if-present
- run: npm test
build:
needs: test
runs-on: ubuntu-latest
steps:
# - name: Checkout repository
# uses: actions/checkout@master
# - name: Setup Node.js
# uses: actions/setup-node@v4
# with:
# node-version: 20
# - name: Install dependencies
# run: npm ci
- name: Build
run: npm run vsce:package
release:
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Create Release
id: create_release
uses: ncipollo/[email protected]
with:
artifacts: "lpc-*.vsix"
bodyFile: "CHANGELOG.md"
prerelease: true