-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
71 lines (62 loc) · 1.64 KB
/
.travis.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
language: node_js
node_js:
- 'node'
services:
- docker
os:
- linux
dist: trusty # using Ubuntu 14.04.5 LTS
branches:
only:
- master
- develop
- /v?[0-9]+\.[0-9]+\.[0-9]+(.*)?/
env:
global:
- ISPRODTAG=^v?[0-9]+\.[0-9]+\.[0-9]+$
- ISTESTTAG=^v?[0-9]+\.[0-9]+\.[0-9]+-[rR][cC]
- RC_EXTENSION_ID="iotdevexbuild.test-albatross"
before_install:
- if [ $TRAVIS_OS_NAME == "linux" ]; then
sudo apt-get update;
sudo apt-get install g++-multilib;
sudo apt-get install -y build-essential;
sudo apt-get install libudev-dev;
fi
- sudo apt-get install libsecret-1-dev
- npm install -g vsce
install:
- npm install
script:
- tsc --version
- npm run check
- node scripts/modifyConfigIfRCVersion.js
- vsce package
deploy:
# deploy to github release
- provider: releases
api_key: $GIT_TOKEN
file_glob: true
file: "*.vsix"
skip_cleanup: true
on:
tags: true
all_branches: true
# deploy to vscode extension market
- provider: script
script: vsce publish -p $VSCE_TOKEN --packagePath *.vsix
skip_cleanup: true
on:
tags: true
all_branches: true
# if it's a PROD tag (something like 1.0.0), then publish extension to market.
condition: "$TRAVIS_TAG =~ $ISPRODTAG"
# deploy test version to vscode extension market
- provider: script
script: yes | vsce unpublish -p $VSCE_TEST_TOKEN $RC_EXTENSION_ID && vsce publish -p $VSCE_TEST_TOKEN --packagePath *.vsix
skip_cleanup: true
on:
tags: true
all_branches: true
# if it's a test version tag (something like 1.0.0-rc), then publish test extension to market.
condition: "$TRAVIS_TAG =~ $ISTESTTAG"