-
-
Notifications
You must be signed in to change notification settings - Fork 28
37 lines (34 loc) · 958 Bytes
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Publish
on:
push:
tags:
- 1.*
jobs:
publish:
name: Publish VS Code Extension
runs-on: ubuntu-latest
steps:
- name: Checkout Tag
uses: actions/checkout@v2
with:
ref: ${{ github.event.push.ref }}
- name: Use Node.js 20
uses: actions/setup-node@v2
with:
node-version: '20'
cache: 'npm'
- name: Install NPM Packages
run: |
npm -v
npm ci
npm install -g vsce ovsx semver
- name: Package
run: vsce package
- name: Publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
file=$(realpath $(ls -t *.vsix | head -1))
vsce publish -i $file -p ${{ secrets.VSCE_TOKEN }}
npx ovsx publish $file -p ${{ secrets.OVSX_TOKEN }}
gh release create '${{ github.ref_name }}' -n "See [Changelog](https://github.com/Serhioromano/vscode-st/blob/master/CHANGELOG.md) for details." $file