-
Notifications
You must be signed in to change notification settings - Fork 13
96 lines (78 loc) · 3.15 KB
/
_move_ide.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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
name: Move IDE
on: workflow_call
concurrency:
group: move-ide-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
move-auto-formatter-test:
name: Move Auto-formatter Test
runs-on: [self-hosted]
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
ref: ${{ github.event.inputs.iota_repo_ref || github.ref }}
- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
with:
node-version: "20"
- name: Install dependencies
working-directory: ./external-crates/move/crates/move-analyzer/prettier-plugin
run: npm install && npm i web-tree-sitter
- name: Run npm test
working-directory: ./external-crates/move/crates/move-analyzer/prettier-plugin
shell: bash
run: npm run test
move-ide-test:
name: Move IDE Test
runs-on: [self-hosted]
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
ref: ${{ github.event.inputs.iota_repo_ref || github.ref }}
- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
with:
node-version: "20"
- name: Install dependencies and start Xvfb (emulate a display so VS Code can be started)
working-directory: ./external-crates/move/crates/move-analyzer/editors/code
run: |
sudo apt install libgtk-3-0 -y
sudo apt-get install -y xvfb x11-apps x11-xkb-utils libx11-6 libx11-xcb1
set -eux
# Start server
/usr/bin/Xvfb :99 -screen 0 1024x768x24 &
sleep 1
ps aux | grep Xvfb --color=always | grep -v grep
sudo add-apt-repository ppa:kisak/kisak-mesa -y
sudo apt update
sudo apt upgrade -y
npm install && npm install --save-dev @types/node @types/semver
- name: Build move-analyzer
run: |
cargo build --bin move-analyzer
mkdir -p ~/.iota/bin
cp ./target/debug/move-analyzer* ~/.iota/bin
- name: Run npm test
working-directory: ./external-crates/move/crates/move-analyzer/editors/code
shell: bash
run: npm run pretest && DISPLAY=:99.0 npm run test
move-vscode-extension-build:
name: Move VSCode extension build
runs-on: [self-hosted]
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
ref: ${{ github.event.inputs.iota_repo_ref || github.ref }}
- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
with:
node-version: "20"
- name: Install dependencies
working-directory: ./external-crates/move/crates/move-analyzer/editors/code
run: npm install && npm install --save-dev @types/node @types/semver
- name: Build VSCode extension
working-directory: ./external-crates/move/crates/move-analyzer/editors/code
run: npm run package