-
Notifications
You must be signed in to change notification settings - Fork 129
/
.travis.yml
66 lines (57 loc) · 2.04 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
language: node_js
os:
- windows
- linux
- osx
node_js:
- '8'
- '9'
- '10'
services:
- docker
cache:
directories:
- node_modules
before_install:
- >
if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
docker pull aliyunfc/runtime-nodejs8:build
docker pull bitnami/minideb:jessie
fi
install:
# Re-checkout files preserving line feeds. This prevents Windows builds from
# converting \n to \r\n.
# see https://github.com/google/wire/blob/master/.travis.yml#L37
- if [[ "$TRAVIS_OS_NAME" == "windows" ]]; then
cd ../..;
mv $TRAVIS_REPO_SLUG _old;
git config --global core.autocrlf false;
git clone _old $TRAVIS_REPO_SLUG;
cd $TRAVIS_REPO_SLUG;
fi
- npm install
- tsc -p ./
- copyfiles -a -u 1 -e "**/*.{js,ts}" "src/**/*" ./
- bash -c 'cd ./lib/utils/fun-nas-server/; npm install'
before_script:
- env | sort
- npm run validate-lint
script:
- |
if [ "$TRAVIS_OS_NAME" = 'windows' ]; then
mocha ./test/ -t 20000 -R spec --recursive -name *.test.js --grep '^(?!Integration::).*'
else
make test
make -C ./lib/utils/fun-nas-server/ test
fi
deploy:
provider: npm
email: [email protected]
api_key:
secure: UJ7hrwXNo/nEDdvtEfwuX7s1lR0vW1Nd9tq4AmeIxG3KtKBAyglfvh/lPKN5eiO4M9Xga2mLNumNgzk6htZc6zUmKBS/uyDP/BfZFZJDkjfUdDl6l5JtLfSXaWBUSHGM2HoqMXoMrQ0RweT565G4hNDSZ/9vt6DjzCp+twOsKeQWqptcTQxgVk19ynz1Ve0dll/ViIxM04R5vWD9ISI6mHjK1lhcrzsw/HMDimzbOoAtyDSWTwconnv23tY5xCgaTSc4Ltvvlq6pQ9Mtt0mHTkFj+q3B16GeqTiHPjk1MVnPBii9Y/MgdeLkz5RDLggTD5/UzhEtqj8O+dTght4O4uRb7pqLCxVzi5atETvSim+Phsc3y159lQmqmcU/bNXl54C1ro44eBlS1jC8gTrK+c5eBAhju2AOBuoMfmNWHc+sXJLxwaW/o+3alsPeTvpYBlJnU2/LpEpWGohjEUAItyMHtp5nhBXCSf3iQAEXN02fRzj8L+fydTPRFzFnNlGB/qZNGxVIjR9JIaUL8a/DjE5Sjt6OXnNofP7CGMZxSStHVyobo0D36gW/4hRR9kymunvdOoKLmk+E1/0A6vutjOf3ajIdDvr9cfEgHFp9X3cl38WHBwNiQOlJxlE+AooMHgtCiO3+ZFcTsae/EJS3p4KOh+Fx+uBEg3aXT6gqa3Y=
on:
tags: true
repo: aliyun/fun
condition: $TRAVIS_TAG = "v$PKG_VERSION"
before_deploy:
- export PKG_VERSION=`node -p "require('./package').version"`