-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy path.azure-pipelines.yml
82 lines (69 loc) · 2.08 KB
/
.azure-pipelines.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
trigger:
branches:
include:
- main
tags:
include:
- v*
- refs/tags/v*
strategy:
matrix:
linux:
imageName: "ubuntu-latest"
# mac:
# imageName: 'macos-latest'
# windows:
# imageName: 'windows-latest'
pool:
vmImage: $(imageName)
variables:
COVERALLS_REPO_TOKEN: $(CoverallsToken)
steps:
- task: NodeTool@0
inputs:
versionSpec: "^18.18.0"
displayName: "Install Node.js"
- bash: |
sudo apt-get update
sudo apt-get -y install curl g++ libcurl4-openssl-dev libncurses5-dev make cmake git tar
displayName: "Install dependencies via apt-get"
condition: and(succeeded(), eq(variables['Agent.OS'], 'Linux'))
- bash: |
git clone https://github.com/realnc/frobtads.git
cd frobtads
./configure
mkdir build
cd build
cmake ..
cmake --build . --target install
sudo make install
displayName: "Fetch, build and install the latest version of frobtads"
condition: and(succeeded(), eq(variables['Agent.OS'], 'Linux'))
# TODO: build for tads3 for mac & windows
# condition: and(succeeded(), eq(variables['Agent.OS'], 'Windows_NT'))
# condition: and(succeeded(), eq(variables['Agent.OS'], 'Darwin'))
- bash: |
/usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
echo ">>> Started xvfb"
displayName: Start xvfb
condition: and(succeeded(), eq(variables['Agent.OS'], 'Linux'))
- bash: |
# echo ">>> Compile vscode-test"
yarn --ignore-engines && yarn compile
# echo ">>> Compiled vscode-test"
echo ">>> Run unit tests test"
yarn coverage
echo ">>> Unit tests finished"
echo ">>> Publish coverage to coveralls"
npx coveralls < ./coverage/lcov.info
displayName: Run Tests
env:
COVERALLS_REPO_TOKEN: $(CoverallsToken)
DISPLAY: ":99.0"
- bash: |
echo ">>> Publish"
yarn deploy
displayName: Publish
condition: and(succeeded(), startsWith(variables['Build.SourceBranch'], 'refs/tags/'), eq(variables['Agent.OS'], 'Linux'))
env:
VSCE_PAT: $(BUILDSECRET)