5. What is gradle ?
Gradle is build automation evolved. Gradle can automate the
building, testing, publishing, deployment and more of software
packages or other types of projects such as generated static
websites, generated documentation or indeed anything else.
Gradle combines the power and flexibility of Ant with the
dependency management and conventions of Maven into a more
effective way to build. Powered by a Groovy DSL and packed
with innovation, Gradle provides a declarative way to describe all
kinds of builds through sensible defaults. Gradle is quickly
becoming the build system of choice for many open source
projects, leading edge enterprises and legacy automation
challenges.
- http://www.gradle.org/
5
6. .. short version
An open source build system that combines the
power of Ant & Maven
6
7. Why gradle ?
• Powerful Build System
• Declarative, Flexible
• Imperative customization
• Tooling API
• Build System Toolkit
• Plugins create own DSL,APIs, IDE integration
• Free / Open Source
7
37. Build variants
• Creating different versions of same
application
• free/paid
• multi-apk
• BuildVariant = Build Type + Product Flavor
37
38. Product Flavors
• Defines a customized version of application
build by the project
• Free / Paid
• Amazon / Play Store / blah store
• Same type as defaultConfig
38
49. Best practice ?
• Import modules manually
• pro
• short compile / AS startup time
• consider project with multiple
libraries..
• con
• no variant builds (ok for most people)
49
73. What & Why ?
• Use aar instead of re-compiling everything
• aar: Binary distribution of an Android
Library Project
• http://tools.android.com/tech-docs/new-
build-system/aar-format
• Time is money
• DRY
73