Skip to content

Instantly share code, notes, and snippets.

@metrafonic
Created March 4, 2014 13:28
Show Gist options
  • Save metrafonic/9346530 to your computer and use it in GitHub Desktop.
Save metrafonic/9346530 to your computer and use it in GitHub Desktop.
Travis Build config
language: java
jdk: oraclejdk7
before_install:
# required libs for android build tools
- sudo apt-get update
- sudo apt-get install -qq --force-yes libgd2-xpm ia32-libs ia32-libs-multiarch
# for gradle output style
- export TERM=dumb
# newer version of gradle
- wget http://services.gradle.org/distributions/gradle-1.10-bin.zip
- unzip -qq gradle-1.10-bin.zip
- export GRADLE_HOME=$PWD/gradle-1.10
- export PATH=$GRADLE_HOME/bin:$PATH
- chmod +x gradlew
# newest Android SDK 22.3
- wget http://dl.google.com/android/android-sdk_r22.3-linux.tgz
- tar -zxf android-sdk_r22.3-linux.tgz
- export ANDROID_HOME=`pwd`/android-sdk-linux
- export PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools
# newest Android NDK
- if [ `uname -m` = x86_64]; then wget http://dl.google.com/android/ndk/android-ndk-r9c-linux-x86_64.tar.bz2 -O ndk.tgz; else wget http://dl.google.com/android/ndk/android-ndk-r9c-linux-x86.tar.bz2 -O ndk.tgz; fi
- tar -xf ndk.tgz
- export ANDROID_NDK_HOME=`pwd`/android-ndk-r9c
- export PATH=${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/platform-tools:${ANDROID_NDK_HOME}
# manually set sdk.dir variable, according to local paths
- echo "sdk.dir=$ANDROID_HOME" > local.properties
- echo yes | android update sdk -a -t tools,platform-tools,extra-android-support,extra-android-m2repository,android-19,build-tools-19.0.1,extra-google-google_play_services,extra-google-m2repository --force --no-ui
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment