Publish on tags update #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish VS Code Extension | |
on: | |
push: | |
tags: | |
- "v[0-9]+.[0-9]+.[0-9]+" | |
jobs: | |
build-and-publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v2 | |
- name: Setup Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: "14" | |
- name: Install Dependencies with Yarn | |
run: yarn install | |
- name: Update Version in package.json | |
run: | | |
VERSION=${GITHUB_REF#refs/tags/} | |
npm version $VERSION --no-git-tag-version | |
- name: Package Extension | |
run: npx vsce package | |
- name: Publish Extension | |
run: npx vsce publish | |
env: | |
VSCE_PAT: ${{ secrets.VSC_PERSONAL_ACCESS_TOKEN }} |