1 #!/bin/sh 2 3 set -e 4 5 SDK_DIR="$HOME/android/android-sdk-linux" 6 NDK_DIR="$HOME/android/android-ndk-r10e" 7 8 generate_local_properties() { 9 : > local.properties 10 echo "sdk.dir=${SDK_DIR}" >> local.properties 11 echo "ndk.dir=${NDK_DIR}" >> local.properties 12 } 13 14 build() { 15 ./gradlew build 16 } 17 18 install() { 19 adb uninstall com.example.Smoke 20 adb install build/outputs/apk/android-fat-debug.apk 21 } 22 23 run() { 24 adb shell am start com.example.Smoke/android.app.NativeActivity 25 } 26 27 generate_local_properties 28 build 29 install 30 #run 31