Skip to content

Release v0.1.2

Release v0.1.2 #36

name: Tests Status
on:
push:
branches: [ master ]
tags:
- 'v*'
pull_request:
branches: [ master ]
jobs:
tests:
name: Unit Tests on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
- name: Install dependencies
run: npm install
- name: Run unit tests
run: npm test
release:
name: Create Github Release + Publish to Marketplace
needs: tests
if: startswith(github.ref, 'refs/tags/v') && github.actor == 'chrisdbeard'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# with:
# fetch-depth: 0
# ref: master
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: npm
- run: npm ci
# - name: Move [Unreleased] to new version in CHANGELOG
# run: |
# VERSION="${GITHUB_REF##*/}"
# DATE=$(date +%Y-*m-%d)
# sed -i.bak "0,/## \[Unreleased\]/s//## [Unreleased]\n\n## [${VERSION}] - ${DATE}/" CHANGELOG.md
# rm CHANGELOG.md.bak
# git config user.name "github-actions"
# git config user.email "github-actions@github.com"
# git commit -am "chore: update CHANGELOG for ${VERSION}"
# git push
- name: Github Release
uses: softprops/action-gh-release@v1
with:
generate_release_notes: true
token: ${{ secrets.GITHUB_TOKEN }}
name: ${{ github.ref_name }}
body: |
# Summary
See the [CHANGELOG.md](https://github.com/${{ github.repository }}/blob/master/CHANGELOG.md)
- name: Install VSCE CLI
run: npm install -g @vscode/vsce
- name: Publish to Visual Studio Marketplace
run: vsce publish -p ${{ secrets.VS_MARKETPLACE_TOKEN }}