This repository has been archived by the owner on Jun 21, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 122
/
.travis.yml
38 lines (37 loc) · 1.65 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
# once a new release tag is created, circle.yml sends a request to travis.yml
# travis.yml builds the documentation in this repo and creates a pull request
language: node_js
notifications:
email: false
cache:
directories:
- node_modules
- /home/travis/.rvm/ # https://docs.travis-ci.com/user/caching/#cache-rvm-ruby-version-for-non-ruby-projects
- $HOME/Library/Caches/Homebrew # caches brew directory
git:
depth: false # make sure we have access to all branches, especially publisher-production
node_js:
- 12
install:
# prevents travis from running package.json > scripts > install
- npm install --ignore-scripts
# links the package to access docs-release-pull-request cli
- npm link @mapbox/docs-release-helpers
env:
# Do not automatically update before running `brew install`, `brew upgrade` or `brew tap`.
HOMEBREW_NO_AUTO_UPDATE: 1
# Do not run `brew cleanup`
HOMEBREW_NO_INSTALL_CLEANUP: 1
jobs:
include:
- name: "Build Maps Release Docs"
os: osx
osx_image: xcode10.2
# only run this job if conditions are met (circleci will trigger it)
if: env(SDK_FLAVOR) = maps AND env(RELEASE_TAG) IS PRESENT
script:
- git config user.email "[email protected]"
# generate the documentation given the release tag and commit it and then
# from the commit created in the shell script, push a new branch, and create a pull request in this repo
- ./scripts/docs-update-maps.sh $RELEASE_TAG && docs-release-pull-request -s $SDK_FLAVOR -t $RELEASE_TAG -b publisher-production -p ios -r mapbox-gl-native-ios
# use `docs-release-pull-request --help` to see all options