1+ ---
12env :
23 # To update the secure tokens, run `travis encrypt NAME='VALUE' --add` after
34 # installing the travis gem with `gem install travis`.
45 global :
56 # variables from the web interface:
67 # - BOT_ITC_PASSWORD_FOR_FASTLANE
78 # - BUGSNAG_KEY: api key for Bugsnag connection
8- # - CI_USER_TOKEN: unknown
9+ # - CI_USER_TOKEN: used to auth with the keys repo
910 # - DANGER_GITHUB_API_TOKEN: api key to let Danger write comments to github
10- # - FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD: app-specific password for the iTMS Transporter (obselete)
1111 # - FASTLANE_PASSWORD: password for apple id used by fastlane
12- # - FASTLANE_SESSION: if fastlane's apple ID has 2fa enabled, this is the 1-month 2fa session cookie
1312 # - GCAL_KEY: google calendar API key
1413 # - GH_TOKEN: unknown
1514 # - GITHUB_PAGES_TOKEN: token to push to gh-pages
1615 # - GMAPS_KEY: google maps API key
1716 # sets our node version in one nice place
1817 - TRAVIS_NODE_VERSION=8
19- # set the ruby version up top
20- - TRAVIS_RUBY_VERSION=ruby-2.4.2
2118 # configure fastlane a bit
2219 - FASTLANE_SKIP_UPDATE_CHECK=1
2320 - FASTLANE_DISABLE_ANIMATION=1
@@ -32,102 +29,36 @@ env:
3229branches :
3330 only :
3431 - master
35- - /^travis/
3632 - /^greenkeeper\//
37- - /^v?(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)(?:-[\da-z\-]+(?:\.[\da-z\-]+)*)?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?$/
3833
3934
4035stages :
4136 - name : Greenkeeper
4237 if : branch =~ ^greenkeeper\/
4338 - name : Deploy Data
4439 if : branch = master AND type != pull_request
45- - name : Build + Deploy
46- if : type = cron OR tag IS present
47-
48-
49- #
50- # Definitions of dictionaries that are used by the machines below
51- #
52-
53- x-definitions :
54- - &base
55- before_install :
56- # dirty hack for https://github.com/travis-ci/travis-ci/issues/5092
57- - export PATH="${PATH/\.\/node_modules\/\.bin/}"
58-
59- # finish bypassing 2fa auth for fastlane
60- - unset FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD
61- - unset FASTLANE_SESSION
62-
63- # print some travis debugging info
64- - echo "Now testing on $TRAVIS_OS_NAME"
65- - echo "Travis branch is $TRAVIS_BRANCH"
66- - echo "Travis is in pull request $TRAVIS_PULL_REQUEST"
67- - echo "Build triggered by $TRAVIS_EVENT_TYPE"
68-
69- # force the ruby we want
70- - echo "Using ruby $TRAVIS_RUBY_VERSION (ruby -v says $(ruby -v))"
71- - rvm use $TRAVIS_RUBY_VERSION --install --binary --create
72- - echo "ruby -v is now $(ruby -v)"
73- - gem install bundler
74-
75- # force a consistent node version
76- - echo "Using node $TRAVIS_NODE_VERSION (node -v says $(node -v))"
77- - nvm install "$TRAVIS_NODE_VERSION"
78- - nvm use "$TRAVIS_NODE_VERSION"
79- - echo "node -v is now $(node -v)"
80-
81- # travis doesn't install yarn automatically on osx
82- - if [[ $TRAVIS_OS_NAME == "osx" ]]; then brew install yarn --without-node; fi
83-
84- install :
85- # install packages (if the first fails, try once more)
86- - yarn || yarn
87-
88- # install fastlane (if at first you don't succeed, try once more)
89- - bundle install || bundle install
90-
91- before_script :
92- # ensure the env file exists and fill it out
93- - touch .env.js
94- - echo "export const GOOGLE_CALENDAR_API_KEY = '$GCAL_KEY'" >> .env.js
95- - echo "export const GOOGLE_MAPS_API_KEY = '$GMAPS_KEY'" >> .env.js
96-
97- # disable npm wrapper for npm scripts
98- - npm config set loglevel=silent
99- - mkdir -p logs/
100-
101- after_script :
102- - npm config set loglevel=notice
103- - npm run danger -- --id $task
104-
105- before_cache :
106- - rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
107- - rm -fr $HOME/.gradle/caches/*/plugin-resolution/
108-
109- - &simplejs
110- os : linux
111- sudo : false
112- distro : trusty
113- language : node_js
114- node_js : $TRAVIS_NODE_VERSION
11540
11641
11742jobs :
118- # We define default before_install, install, and before_script steps.
119- # To skip the default step, use `step_name: skip`.
12043 include :
12144 # Run greenkeeper stuff
122- - << : *simplejs
45+ - os : linux
46+ sudo : false
47+ distro : trusty
48+ language : node_js
49+ node_js : $TRAVIS_NODE_VERSION
12350 stage : Greenkeeper
12451 env : [task=GREENKEEPER]
12552 install : npm install -g greenkeeper-lockfile@1
12653 script : greenkeeper-lockfile-update
12754 after_script : greenkeeper-lockfile-upload
12855
12956 # Deploy the gh-pages data
130- - << : *simplejs
57+ - os : linux
58+ sudo : false
59+ distro : trusty
60+ language : node_js
61+ node_js : $TRAVIS_NODE_VERSION
13162 stage : Deploy Data
13263 env : [task=GH_PAGES]
13364 install : yarn || yarn
@@ -141,48 +72,5 @@ jobs:
14172 github_token : $GITHUB_PAGES_TOKEN
14273 local_dir : docs/
14374
144- # Build/deploy the Android binary
145- - << : *base
146- stage : Build + Deploy
147- os : linux
148- sudo : required
149- distro : trusty
150- language : android
151- env : [task=ANDROID]
152- android :
153- components :
154- - tools
155- - platform-tools
156- - build-tools-23.0.1
157- - build-tools-23.0.2
158- - build-tools-25.0.0
159- - build-tools-25.0.1
160- - build-tools-25.0.2
161- - build-tools-25.0.3
162- - build-tools-26.0.1
163- - android-23
164- - android-25
165- - android-26
166- - extra-android-m2repository
167- - extra-google-m2repository
168- script :
169- - bundle exec fastlane android ci-run | tee ./logs/build
170-
171- # Build/deploy the iOS binary
172- - << : *base
173- stage : Build + Deploy
174- os : osx
175- language : objective-c
176- osx_image : xcode9.2
177- env : [task=IOS]
178- script :
179- - bundle exec fastlane ios ci-run | tee ./logs/build
180- - python2 ./scripts/analyze-gym.py -s 20 < ./logs/build | tee ./logs/analysis || true
181-
18275cache :
183- bundler : true
18476 yarn : true
185- directories :
186- - $HOME/.gradle
187- - $HOME/.gradle/wrapper/
188- - $HOME/.android/build-cache
0 commit comments