Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Main build.gradle for a project that has (old versions of) ActionBarSherlock and ViewPagerIndicator included as source. These two projects are configured in the main build file.
apply plugin: 'android'
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:0.6+'
}
}
repositories {
mavenCentral()
}
version = "1.0.0"
archivesBaseName = "myapp-v${version}"
android {
compileSdkVersion 19
buildToolsVersion "19.0.0"
defaultConfig {
targetSdkVersion 19
minSdkVersion 7
versionCode 1
versionName version
}
// ... other config here...
}
dependencies {
compile 'com.android.support:support-v4:13.+'
// these are configured in this build file and in settings.gradle
compile project(':ActionBarSherlock')
compile project(':ViewPagerIndicator')
}
project(':ActionBarSherlock') {
apply plugin: 'android-library'
android {
compileSdkVersion 17
buildToolsVersion "19.0.0"
defaultConfig {
targetSdkVersion 16
}
sourceSets {
main {
manifest.srcFile 'AndroidManifest.xml'
java.srcDirs = ['src']
resources.srcDirs = ['src']
aidl.srcDirs = ['src']
renderscript.srcDirs = ['src']
res.srcDirs = ['res']
assets.srcDirs = ['assets']
}
instrumentTest.setRoot('tests')
}
}
dependencies {
compile 'com.android.support:support-v4:13.+'
}
}
project(':ViewPagerIndicator') {
apply plugin: 'android-library'
android {
compileSdkVersion 17
buildToolsVersion "19.0.0"
defaultConfig {
targetSdkVersion 16
}
sourceSets {
main {
manifest.srcFile 'AndroidManifest.xml'
java.srcDirs = ['src']
resources.srcDirs = ['src']
aidl.srcDirs = ['src']
renderscript.srcDirs = ['src']
res.srcDirs = ['res']
assets.srcDirs = ['assets']
}
instrumentTest.setRoot('tests')
}
}
dependencies {
compile 'com.android.support:support-v4:13.+'
}
}
include ':ActionBarSherlock', ':ViewPagerIndicator'
// Map the projects given their path on disk. This also solves a problem for me with AS not recognizing the projects
// as separate modules, but YMMV.
project(":ViewPagerIndicator").projectDir = new File("libraries/ViewPagerIndicator/library")
project(":ActionBarSherlock").projectDir = new File("libraries/ActionBarSherlock/library")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.