-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (52 loc) · 1.52 KB
/
Copy pathvscode-extension.yml
File metadata and controls
64 lines (52 loc) · 1.52 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: VS Code Extension
on:
push:
branches: [main]
paths: ['packages/vscode-extension/**']
pull_request:
paths: ['packages/vscode-extension/**']
release:
types: [published]
defaults:
run:
working-directory: packages/vscode-extension
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
cache-dependency-path: packages/vscode-extension/package-lock.json
- run: npm ci
- run: npm run compile
- name: Package .vsix
run: npx @vscode/vsce package --out build/
- name: Upload .vsix artifact
uses: actions/upload-artifact@v4
with:
name: chalk-skills-vsix
path: packages/vscode-extension/build/*.vsix
publish:
if: github.event_name == 'release'
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
cache-dependency-path: packages/vscode-extension/package-lock.json
- run: npm ci
- name: Publish to VS Code Marketplace
run: npx @vscode/vsce publish
env:
VSCE_PAT: ${{ secrets.VSCE_PAT }}
- name: Publish to Open VSX
run: npx ovsx publish --pat ${{ secrets.OVSX_PAT }}
env:
OVSX_PAT: ${{ secrets.OVSX_PAT }}
continue-on-error: true # Optional — don't fail if Open VSX isn't set up yet