forked from thom4parisot/nodebook
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
89 lines (82 loc) · 1.99 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
dist: xenial
language: node_js
cache: npm
addons:
ssh_known_hosts: ssh-oncletom.alwaysdata.net
apt:
packages:
- libxml2-utils
node_js: v10
env:
- npm_version=6
DEBUG=tape-spawn
SHARP_IGNORE_GLOBAL_LIBVIPS=1
# before_install:
# - npm i -g npm@${npm_version}
before_install:
- npm config --global set prefer-offline true
install:
- npm ci
- npm run install:all
script:
- ./bin/cli.js --help
- npm test
- make build-html
- make build-odt
- xmllint --noout dist/book.fodt 2>&1
before_deploy:
- openssl aes-256-cbc -K $encrypted_5256f0527d52_key -iv $encrypted_5256f0527d52_iv -in deploykey_ed25519.enc -out /tmp/deploykey -d
- eval "$(ssh-agent -s)" && chmod 600 /tmp/deploykey && ssh-add /tmp/deploykey
- git-lfs pull
- make build-docbook
deploy:
- provider: script
skip-cleanup: true
local-dir: dist
script: rsync -r --delete-after --quiet $TRAVIS_BUILD_DIR/dist/ [email protected]:~/node.js/v1/
on:
branch: v1
- provider: script
skip-cleanup: true
local-dir: dist
script: rsync -r --delete-after --quiet $TRAVIS_BUILD_DIR/dist/ [email protected]:~/node.js/v2/
on:
branch: master
- provider: releases
prerelease: false
skip-cleanup: true
api-key: "$GH_TOKEN"
file-glob: true
file: dist/book.*
on:
tags: true
all-branches: true
condition: $TRAVIS_BRANCH =~ ^v1.
- provider: releases
prerelease: true
skip-cleanup: true
api-key: "$GH_TOKEN"
file-glob: true
file: dist/book.*
on:
tags: true
all-branches: true
condition: $TRAVIS_BRANCH =~ ^v2.
- provider: npm
tag: latest
skip-cleanup: true
on:
tags: true
all-branches: true
condition: $TRAVIS_BRANCH =~ ^v1.
email: "[email protected]"
api-key: "$NPM_TOKEN"
- provider: npm
tag: next
skip-cleanup: true
on:
tags: true
all-branches: true
condition: $TRAVIS_BRANCH =~ ^v2.
email: "[email protected]"
api-key: "$NPM_TOKEN"