-
-
Notifications
You must be signed in to change notification settings - Fork 52
40 lines (32 loc) · 996 Bytes
/
release.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
38
39
40
name: Release
on:
workflow_run:
workflows: ['Test']
branches: [master]
types: [completed]
jobs:
deploy:
name: Conditionally Release and Deploy # depends on the content of CHANGELOG.md
runs-on: ubuntu-latest
environment: Release
if: github.event.workflow_run.conclusion == 'success' && github.ref == 'refs/heads/master' && github.repository_owner == 'matepek'
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
persist-credentials: false # to drop github token and used GITHUBM_API_KEY
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: '16.x'
- name: Install
run: npm install
- name: Audit
run: npm audit --production
- name: Compile
run: npm run compile
- name: Deploy
run: npm run deploy
env:
VSCE_PAT: ${{ secrets.VSCE_PAT }}
GITHUBM_API_KEY: ${{ secrets.GITHUBM_API_KEY }}