From 50f69f22dfe35dc65119b03454410f24998755c1 Mon Sep 17 00:00:00 2001 From: Kentaro Takiguchi Date: Tue, 15 Jul 2014 17:35:26 +0900 Subject: [PATCH 1/4] Add gitignore --- .gitignore | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000..16f7e8aec9 --- /dev/null +++ b/.gitignore @@ -0,0 +1,39 @@ +# Android generated +bin +gen +lint.xml + +# IntelliJ IDEA +.idea +*.iml +*.ipr +*.iws +classes +gen-external-apklibs + +# Eclipse +.project +.classpath +.settings +.checkstyle + +# Gradle +.gradle +build +out + +# Maven +target +release.properties +pom.xml.* + +# Ant +ant.properties +local.properties +proguard.cfg +proguard-project.txt + +# Other +.DS_Store +dist +tmp From 5a888f3a6de3694e7da4b56b2939d2ae50bedc63 Mon Sep 17 00:00:00 2001 From: Kentaro Takiguchi Date: Tue, 15 Jul 2014 17:38:50 +0900 Subject: [PATCH 2/4] Update tools version --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 2d29f854be..a444cfb512 100644 --- a/build.gradle +++ b/build.gradle @@ -19,7 +19,7 @@ buildscript { mavenCentral() } dependencies { - classpath 'com.android.tools.build:gradle:0.10.+' + classpath 'com.android.tools.build:gradle:0.12.+' } } From fa83b2fa5e9b7e348b763c1f6b1822e8b6cf9340 Mon Sep 17 00:00:00 2001 From: Kentaro Takiguchi Date: Tue, 15 Jul 2014 17:43:34 +0900 Subject: [PATCH 3/4] Add jarRelease task --- library/build.gradle | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/library/build.gradle b/library/build.gradle index 5b751a0820..68a489b08a 100644 --- a/library/build.gradle +++ b/library/build.gradle @@ -36,3 +36,14 @@ android { dependencies { } + +android.libraryVariants.all { variant -> + def name = variant.buildType.name + if (name.equals(com.android.builder.core.BuilderConstants.DEBUG)) { + return; // Skip debug builds. + } + def task = project.tasks.create "jar${name.capitalize()}", Jar + task.dependsOn variant.javaCompile + task.from variant.javaCompile.destinationDir + artifacts.add('archives', task); +} From e33f5a514c79f3b3126a7f12aa668fe3aea61c3b Mon Sep 17 00:00:00 2001 From: rejasupotaro Date: Tue, 15 Jul 2014 17:49:46 +0900 Subject: [PATCH 4/4] Update README.md --- README.md | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 7efc281f85..6faf3a264b 100644 --- a/README.md +++ b/README.md @@ -55,6 +55,22 @@ accompanying demo application. To get started: ## Using Gradle ## -ExoPlayer can also be built using Gradle. For a complete list of tasks, run: +ExoPlayer can also be built using Gradle. You can include it as a dependent project and build from source. e.g. -./gradlew tasks +``` +// setting.gradle +include ':app', ':..:ExoPlayer:library' + +// app/build.gradle +dependencies { + compile project(':..:ExoPlayer:library') +} +``` + +If you want to use ExoPlayer as a jar, run: + +``` +./gradlew jarRelease +``` + +and copy library.jar to the libs-folder of your new project.