1 2 buildscript { 3 repositories { 4 jcenter() 5 } 6 7 dependencies { 8 classpath 'com.android.tools.build:gradle:2.1.2' 9 } 10 } 11 12 apply plugin: 'com.android.application' 13 14 15 16 repositories { 17 jcenter() 18 } 19 20 dependencies { 21 compile 'com.google.android.gms:play-services-location:8.4.0' 22 compile 'com.google.android.gms:play-services-wearable:8.4.0' 23 compile 'com.android.support:support-v13:24.1.1' 24 25 compile 'com.google.android.support:wearable:1.4.0' 26 27 compile project(':Shared') 28 } 29 30 // The sample build uses multiple directories to 31 // keep boilerplate and common code separate from 32 // the main sample code. 33 List<String> dirs = [ 34 'main', // main sample code; look here for the interesting stuff. 35 'common', // components that are reused by multiple samples 36 'template'] // boilerplate code that is generated by the sample template process 37 38 android { 39 compileSdkVersion 24 40 41 buildToolsVersion "24.0.1" 42 43 defaultConfig { 44 versionCode 1 45 versionName "1.0" 46 47 targetSdkVersion 22 48 49 } 50 51 compileOptions { 52 sourceCompatibility JavaVersion.VERSION_1_7 53 targetCompatibility JavaVersion.VERSION_1_7 54 } 55 56 sourceSets { 57 main { 58 dirs.each { dir -> 59 java.srcDirs "src/${dir}/java" 60 res.srcDirs "src/${dir}/res" 61 } 62 } 63 androidTest.setRoot('tests') 64 androidTest.java.srcDirs = ['tests/src'] 65 66 } 67 } 68