Skip to content

Instantly share code, notes, and snippets.

@RubenSandwich
Created July 11, 2018 19:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save RubenSandwich/251e1b6ffdffc58b5b1aeb2b77e9b7ce to your computer and use it in GitHub Desktop.
Save RubenSandwich/251e1b6ffdffc58b5b1aeb2b77e9b7ce to your computer and use it in GitHub Desktop.
Travis CI File
install:
- yarn install
cache:
yarn: true
stages:
- Test
- name: Build
if: (branch != master) AND (branch != dev)
- name: Deploy
if: (type = pull_request) OR (branch IN (dev, master))
jobs:
include:
- stage: Test
os: linux
dist: trusty
before_install:
- nvm install 9.5.0
script:
- yarn lint
- yarn test
- stage: Build
os: linux
dist: trusty
language: android
gemfile: Gemfile
android:
components:
- build-tools-27.0.3
- android-27
- extra-android-m2repository
- extra-google-google_play_services
- extra-google-m2repository
- addon-google_apis-google-16
before_install:
- bundler install --jobs=3 --retry=3
- nvm install 9.5.0
script:
- bundler exec fastlane android build
- stage: Deploy
os: linux
dist: trusty
language: android
gemfile: Gemfile
android:
components:
- build-tools-27.0.3
- android-27
- extra-android-m2repository
- extra-google-google_play_services
- extra-google-m2repository
- addon-google_apis-google-16
before_install:
- bundler install --jobs=3 --retry=3
- nvm install 9.5.0
script:
- bundler exec fastlane android deploy
- stage: Build
os: osx
osx_image: xcode9.2
language: objective-c
gemfile: Gemfile
rvm:
- 2.4.2
before_install:
- brew install yarn
- bundler install --jobs=3 --retry=3
script:
- bundler exec fastlane ios build
- stage: Deploy
os: osx
osx_image: xcode9.2
language: objective-c
gemfile: Gemfile
rvm:
- 2.4.2
before_install:
- brew install yarn
- bundler install --jobs=3 --retry=3
script:
- bundler exec fastlane ios deploy
notifications:
slack:
rooms:
- INSERT YOUR SLACK API KEY HERE
@RubenSandwich
Copy link
Author

This assumes you are using bundler to install Fastlane, which you should.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment