Skip to content

Commit d798e0a

Browse files
committed
Merge branch 'main' of github.com:c3lang/vscode-c3
2 parents 7b59fe2 + 132ec48 commit d798e0a

File tree

11 files changed

+1632
-53
lines changed

11 files changed

+1632
-53
lines changed

.github/workflows/deploy.yml

Lines changed: 39 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,56 @@
1-
name: Build & Deploy
1+
name: Build, Test & Deploy
2+
23
on:
34
push:
45
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
workflow_dispatch:
59

610
jobs:
7-
deploy:
11+
build-and-test:
812
runs-on: ubuntu-latest
913
steps:
10-
- uses: actions/checkout@v1
14+
- uses: actions/checkout@v4
15+
16+
- name: Use Node.js
17+
uses: actions/setup-node@v4
18+
with:
19+
node-version: '22'
20+
cache: 'npm'
21+
22+
- name: Install dependencies
23+
run: npm install
24+
1125
- name: Build project
12-
run: |
13-
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash &&
14-
export NVM_DIR="$HOME/.nvm"
15-
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
16-
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"
17-
18-
nvm use system
19-
20-
nvm install 22
21-
nvm use 22
22-
npm install
23-
npm install --only-dev
24-
npm run build
25-
26-
- uses: actions/upload-artifact@v4
26+
run: npm run build
27+
28+
- name: Run tests
29+
run: xvfb-run -a npm test
30+
31+
- name: Upload Artifact
32+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
33+
uses: actions/upload-artifact@v4
2734
with:
2835
name: vscode-c3
2936
path: "*.vsix"
3037

38+
release:
39+
needs: build-and-test
40+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
41+
runs-on: ubuntu-latest
42+
steps:
43+
- uses: actions/checkout@v4
44+
45+
- name: Download Artifact
46+
uses: actions/download-artifact@v4
47+
with:
48+
name: vscode-c3
49+
3150
- name: Create Release
3251
uses: softprops/action-gh-release@v2
3352
with:
3453
tag_name: latest
35-
name: latest
54+
name: Latest Release
3655
files: vscode-c3.vsix
37-
generate_release_notes: false
56+
generate_release_notes: true

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@ Makefile
33
.DS_Store
44
*.vsix
55
dist/
6+
.vscode/.vscode-test
7+
.claude
68
.vscode/
7-
.claude

0 commit comments

Comments
 (0)