mirror of
https://github.com/Etar-Group/Etar-Calendar.git
synced 2024-09-11 10:05:47 +03:00
Use gradle
This commit is contained in:
parent
7ef91824e6
commit
7c37e2a474
12
README.md
12
README.md
@ -3,15 +3,5 @@
|
||||
git submodule init
|
||||
git submodule update
|
||||
|
||||
android update project -p .
|
||||
android update project -p external/ex/chips -t android-18
|
||||
android update project -p external/calendar
|
||||
android update project -p external/colorpicker
|
||||
android update project -p external/datetimepicker
|
||||
android update project -p external/timezonepicker
|
||||
|
||||
rm external/datetimepicker/libs/android-support-v4.jar
|
||||
cp -f libs/android-support-v4.jar external/datetimepicker/libs/android-support-v4.jar
|
||||
rm external/timezonepicker/libs/android-support-v4.jar
|
||||
cp -f libs/android-support-v4.jar external/timezonepicker/libs/android-support-v4.jar
|
||||
gradle build
|
||||
```
|
||||
|
169
build.gradle
Normal file
169
build.gradle
Normal file
@ -0,0 +1,169 @@
|
||||
buildscript {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
dependencies {
|
||||
classpath 'com.android.tools.build:gradle:0.6.+'
|
||||
}
|
||||
}
|
||||
|
||||
allprojects {
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
}
|
||||
|
||||
task wrapper(type: Wrapper) {
|
||||
gradleVersion = '1.8'
|
||||
}
|
||||
|
||||
project(':external:calendar') {
|
||||
apply plugin: 'android-library'
|
||||
|
||||
android {
|
||||
compileSdkVersion 18
|
||||
buildToolsVersion '18.1.1'
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
java.srcDirs = ['src']
|
||||
res.srcDirs = ['res']
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
project(':external:colorpicker') {
|
||||
apply plugin: 'android-library'
|
||||
|
||||
android {
|
||||
compileSdkVersion 18
|
||||
buildToolsVersion '18.1.1'
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
java.srcDirs = ['src']
|
||||
res.srcDirs = ['res']
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
project(':external:datetimepicker') {
|
||||
apply plugin: 'android-library'
|
||||
|
||||
dependencies {
|
||||
compile 'com.android.support:support-v4:18.0.+'
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 18
|
||||
buildToolsVersion '18.1.1'
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
java.srcDirs = ['src']
|
||||
res.srcDirs = ['res']
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
project(':external:timezonepicker') {
|
||||
apply plugin: 'android-library'
|
||||
|
||||
dependencies {
|
||||
compile 'com.android.support:support-v4:18.0.+'
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 18
|
||||
buildToolsVersion '18.1.1'
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
java.srcDirs = ['src']
|
||||
res.srcDirs = ['res']
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
project(':external:ex:chips') {
|
||||
apply plugin: 'android-library'
|
||||
|
||||
android {
|
||||
compileSdkVersion 18
|
||||
buildToolsVersion '18.1.1'
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
java.srcDirs = ['src']
|
||||
res.srcDirs = ['res']
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
apply plugin: 'android'
|
||||
|
||||
dependencies {
|
||||
compile 'com.android.support:support-v4:18.0.+'
|
||||
compile project(':external:calendar')
|
||||
compile project(':external:colorpicker')
|
||||
compile project(':external:datetimepicker')
|
||||
compile project(':external:timezonepicker')
|
||||
compile project(':external:ex:chips')
|
||||
}
|
||||
|
||||
android {
|
||||
compileSdkVersion 18
|
||||
buildToolsVersion "18.1.1"
|
||||
|
||||
defaultConfig {
|
||||
minSdkVersion 15
|
||||
targetSdkVersion 18
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
java.srcDirs = ['src', 'external/ex/common/java'] // NOTE: this includes external/ex/common/java!
|
||||
res.srcDirs = ['res']
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* To sign release build, create file gradle.properties in ~/.gradle/ with this content:
|
||||
*
|
||||
* signingStoreLocation=/home/key.store
|
||||
* signingStorePassword=xxx
|
||||
* signingKeyAlias=alias
|
||||
* signingKeyPassword=xxx
|
||||
*/
|
||||
if (project.hasProperty('signingStoreLocation') &&
|
||||
project.hasProperty('signingStorePassword') &&
|
||||
project.hasProperty('signingKeyAlias') &&
|
||||
project.hasProperty('signingKeyPassword')) {
|
||||
println "Found sign properties in gradle.properties! Signing build…"
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
storeFile file(signingStoreLocation)
|
||||
storePassword signingStorePassword
|
||||
keyAlias signingKeyAlias
|
||||
keyPassword signingKeyPassword
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes.release.signingConfig = signingConfigs.release
|
||||
} else {
|
||||
buildTypes.release.signingConfig = null
|
||||
}
|
||||
}
|
5
settings.gradle
Normal file
5
settings.gradle
Normal file
@ -0,0 +1,5 @@
|
||||
include ':external:calendar'
|
||||
include ':external:colorpicker'
|
||||
include ':external:datetimepicker'
|
||||
include ':external:timezonepicker'
|
||||
include ':external:ex:chips'
|
Loading…
Reference in New Issue
Block a user