Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Using travis function submodule
- Loading branch information
Showing
7 changed files
with
48 additions
and
123 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[submodule "travis"] | ||
path = travis | ||
url = https://github.com/nemgrouplimited/travis-functions.git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,54 @@ | ||
dist: bionic | ||
language: node_js | ||
node_js: | ||
- "10" | ||
- "12" | ||
- 10 | ||
- 12 | ||
services: | ||
- docker | ||
env: | ||
global: | ||
- DEV_BRANCH=dev | ||
- RELEASE_BRANCH=main | ||
- POST_RELEASE_BRANCH=main | ||
- RELEASE_MESSAGE=release | ||
cache: | ||
directories: | ||
- "node_modules" | ||
- .eslintcache | ||
jobs: | ||
include: | ||
- stage: e2e | ||
script: npm run test:e2e | ||
if: branch = e2e | ||
before_script: | ||
- npm run build | ||
- if [ "$TRAVIS_NODE_VERSION" = "10" ] || [ "$TRAVIS_NODE_VERSION" = "12" ]; then npm run lint; fi | ||
- . ./travis/node-functions.sh | ||
- VERSION="$(node_load_version)" | ||
- log_env_variables | ||
script: | ||
- npm run test:cov | ||
- npm run doc | ||
- touch ./ts-docs/.nojekyll | ||
- if [ "$TRAVIS_NODE_VERSION" = "10" ]; then npm run coveralls-report; fi | ||
deploy: | ||
- provider: script | ||
skip_cleanup: true | ||
script: /bin/sh travis/github-pages.sh | ||
on: | ||
branch: main | ||
node_js: "12" | ||
- provider: script | ||
skip_cleanup: true | ||
script: /bin/sh travis/uploadArchives.sh | ||
on: | ||
branch: main | ||
node_js: "10" | ||
- provider: script | ||
skip_cleanup: true | ||
script: /bin/sh travis/release.sh | ||
on: | ||
branch: $RELEASE_BRANCH | ||
node_js: "10" | ||
jobs: | ||
include: | ||
- stage: test | ||
name: docs | ||
script: npm run doc | ||
- stage: test | ||
name: lint | ||
script: npm run lint | ||
- name: e2e | ||
script: npm run e2e | ||
if: (branch = env(DEV_BRANCH) AND type = cron) OR (commit_message = e2e) | ||
- stage: publish | ||
name: github alpha pages | ||
script: /bin/bash travis/node-functions.sh node_push_github_pages | ||
if: branch = env(DEV_BRANCH) AND type = push | ||
- name: alpha npm | ||
script: npm pack && /bin/bash travis/node-functions.sh node_publish_alpha | ||
if: branch = env(DEV_BRANCH) AND type = push | ||
- stage: release | ||
name: release npm | ||
script: npm pack && /bin/bash travis/node-functions.sh node_publish_release | ||
if: branch = env(RELEASE_BRANCH) AND type = api AND commit_message = env(RELEASE_MESSAGE) | ||
- stage: release | ||
name: github release pages | ||
script: /bin/bash travis/node-functions.sh node_push_github_pages | ||
if: branch = env(RELEASE_BRANCH) AND type = api AND commit_message = env(RELEASE_MESSAGE) | ||
- stage: post release | ||
name: tag and version upgrade | ||
script: npm pack && /bin/bash travis/node-functions.sh node_post_release | ||
if: branch = env(RELEASE_BRANCH) AND type = api AND commit_message = env(RELEASE_MESSAGE) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.