-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
44 lines (42 loc) · 2.66 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
language: node_js
node_js:
- 12.13.0
addons:
- chrome: stable
jobs:
include:
- stage: test
script:
- echo 'Running tests..'
- npm run test
- stage: deploy
script:
- echo 'Deploying'
- |
set -ev
ENCRYPTED_KEY_VAR="encrypted_${ENCRYPTION_LABEL}_key"
ENCRYPTED_IV_VAR="encrypted_${ENCRYPTION_LABEL}_iv"
ENCRYPTED_KEY=${!ENCRYPTED_KEY_VAR}
ENCRYPTED_IV=${!ENCRYPTED_IV_VAR}
if [[ $ENCRYPTED_KEY == "" ]]; then
echo "Auto-deploy GitHub key missing; exiting without a build"
exit 0
fi
$(npm bin)/set-up-ssh --key "$ENCRYPTED_KEY" \
--iv "$ENCRYPTED_IV" \
--path-encrypted-key "travis/github_deploy_key.enc"
$(npm bin)/update-branch --commands "ng deploy --base-href ./" \
--commit-message "Deploying to github pages" \
--directory "dist" \
--distribution-branch "gh-pages" \
--source-branch "master" \
stages:
- name: test
if: type = pull_request
- name: deploy
if: type = push AND branch = master
env:
global:
- ENCRYPTION_LABEL: "58a1aa26d61a"
- secure: rEcDiR+RowI87H/BE5blDMOZapO4RTlYJyCZy8AEcm5qg33EGqWE1jli6I46VJDuqDQoaM62zMh7Vnksf9CarHNaBzoaAAqLwtJP7lGS3xGJDfbeVfaYSu9faJdskEOUsJY1usMBrw0ach3g3RUN6k7umv8omcwdc/bP7WdlcPipZu2fJZC4mHSKf+K4H/HxotWwKvXdL4Tzjcq5ZDXd2yObIFbfYaP34m+N82JBEuz6bK41TK45hCitTXVLq3Av9Ymuc8pxvFEgRBrAL/6f7FWTTxliekxNNbAHLXodVM7S47iMLWlKNAyj9qlDhfX5IHU0XGLUwOKjBpL6Xm64TpZR3DYVHJMF40gtdxgI2j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