Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Rock the Gradle, Rule the World
Search
Xavier F. Gouchet
PRO
April 01, 2019
Programming
0
44
Rock the Gradle, Rule the World
Xavier F. Gouchet
PRO
April 01, 2019
Tweet
Share
More Decks by Xavier F. Gouchet
See All by Xavier F. Gouchet
Being an ethical software engineer
xgouchet
PRO
0
280
Libérez votre créativité
xgouchet
PRO
0
110
Unleash your Programming Creativity
xgouchet
PRO
0
170
Demystifying the Test Pyramid
xgouchet
PRO
1
530
Successfully Publishing a Tested, Upgradeable and Documented Open Source Library
xgouchet
PRO
0
110
Property Based Testing in Practice
xgouchet
PRO
0
84
Develop your CI tools
xgouchet
PRO
2
410
How to write a safe and reliable Open Source Library
xgouchet
PRO
1
280
Benchmarking your app's performance
xgouchet
PRO
0
230
Other Decks in Programming
See All in Programming
コンテキストエンジニアリング Cursor編
kinopeee
1
700
フロントエンドのmonorepo化と責務分離のリアーキテクト
kajitack
2
140
Rancher と Terraform
fufuhu
0
100
あのころの iPod を どうにか再生させたい
orumin
2
2.5k
学習を成果に繋げるための個人開発の考え方 〜 「学習のための個人開発」のすすめ / personal project for leaning
panda_program
1
110
サイトを作ったらNFCタグキーホルダーを爆速で作れ!
yuukis
0
490
ゲームの物理
fadis
5
1.5k
Portapad紹介プレゼンテーション
gotoumakakeru
1
130
ライブ配信サービスの インフラのジレンマ -マルチクラウドに至ったワケ-
mirrativ
2
260
WebAssemblyインタプリタを書く ~Component Modelを添えて~
ruccho
1
910
Nuances on Kubernetes - RubyConf Taiwan 2025
envek
0
190
オープンセミナー2025@広島LT技術ブログを続けるには
satoshi256kbyte
0
120
Featured
See All Featured
How to Ace a Technical Interview
jacobian
279
23k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
667
120k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
33
2.4k
How to Think Like a Performance Engineer
csswizardry
25
1.8k
Code Review Best Practice
trishagee
70
19k
Side Projects
sachag
455
43k
Facilitating Awesome Meetings
lara
55
6.5k
Reflections from 52 weeks, 52 projects
jeffersonlam
351
21k
Site-Speed That Sticks
csswizardry
10
780
Designing Experiences People Love
moore
142
24k
Music & Morning Musume
bryan
46
6.7k
Transcript
Rock the Gradle Rule the world
About… Lead Android Engineer at WorkWell Fluent in Android since
Cupcake 2
A brief introduction 1
Dependency Management System What is Gradle General Purpose Build management
4
5 General purpose Language agnostic Feature agnostic
6 Dependency management system Knows how to graph and resolve
dependencies ◇ code ◇ tasks ◇ …
7 Build management Based on tasks created by plugins
Configuration Gradle flow Initialisation Execution 8
9 Initialisation Launches the JVM (with proper params) Analyse the
working directory Reads the settings.gradle file Creates the Project object(s) that will be used Compiles, test and add buildSrc to the classpath
10 Configuration Execute all the build.gradle scripts in the project
Create all the Task objects and configure the Project object(s) Resolves the tasks dependencies
11 Execution List the Task to run based on the
invocation (and their dependencies) Execute each of the tasks
Meet the buildSrc folder 2
Project structure ┬ MyProject ├┬ app/ │├── src/ │└── build.gradle
├┬ buildSrc/ │├── src/ │├── build.gradle │└── settings.gradle ├─ build.gradle └─ settings.gradle 13
Purposes… ◇ Better dependency management ◇ Helper classes / methods
◇ Custom tasks in dedicated classes ◇ Custom plugin ■ Locally versionned with the project 14
How does it work? ◇ Works like any module in
your project ◇ Compiled and tested before any gradle task ◇ Groovy, Java, Kotlin, … ◇ Any public class / method becomes availble in gradle scripts 15
“ A change in buildSrc causes the whole project to
become out-of-date. 16
apply plugin: 'groovy' dependencies { compile gradleApi() compile localGroovy() }
17 Default build.gradle
Writin a Plugin 3
Hands On 19
Thanks! Any questions? ◇ https://github.com/xgouchet/RockTheGradle ◇ @xgouchet 20