-
Notifications
You must be signed in to change notification settings - Fork 2
73 lines (61 loc) · 1.61 KB
/
test.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
name: Build
on:
push:
branches:
- main
tags:
- "v*.*.*"
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup npm
uses: actions/setup-node@v4
with:
node-version: 20
registry-url: https://registry.npmjs.org/
- name: Install X server
run: |
sudo apt-get update
sudo apt-get install -y xvfb
- name: Install the dependencies
run: npm clean-install && npm run postinstall
- name: Build package
run: npm run esbuild
- name: Test language server
run: npm run test:server
- name: Test language server client
run: |
Xvfb -ac :99 -screen 0 1280x1024x16 &
export DISPLAY=:99
npm run test
- name: Package Extension
run: npx vsce package
- name: Archive vsix package
uses: actions/upload-artifact@v4
with:
name: modelica-language-server.vsix
path: modelica-language-server-*.vsix
release:
if: startsWith(github.ref, 'refs/tags/')
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/download-artifact@v4
with:
name: modelica-language-server.vsix
- name: Release
uses: softprops/action-gh-release@v1
with:
files: |
modelica-language-server-*.vsix
fail_on_unmatched_files: true
generate_release_notes: true
append_body: true