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
Gradle Dive: Writing Custom Plugins
Search
Theophilus Kibet
November 15, 2022
Programming
0
46
Gradle Dive: Writing Custom Plugins
Theophilus Kibet
November 15, 2022
Tweet
Share
More Decks by Theophilus Kibet
See All by Theophilus Kibet
From Source to Bytecode: Understanding the Kotlin Compilation Process
kibet
0
61
Building Cross- Platform Applications with Kotlin Multiplatform
kibet
0
18
Crafting Custom Lint Rules: Elevating Android Code Quality
kibet
0
67
Mastering GitHub Actions: Automate and Supercharge Your Development Workflow
kibet
0
72
Build Configurations: types, variants and flavors.
kibet
0
58
Opportunities in Tech
kibet
0
79
Introduction To Android Development
kibet
0
47
Other Decks in Programming
See All in Programming
エンジニアとして高みを目指す、 利益を生み出す設計の考え方 / design-for-profit
minodriven
24
12k
Devvox Belgium - Agentic AI Patterns
kdubois
1
100
The Flutter Journey of Building a Live Streaming App — With a Side of Performance Tuning
u503
1
110
GitHub Actions × AWS OIDC連携の仕組みと経緯を理解する
ota1022
0
250
Web フロントエンドエンジニアに開かれる AI Agent プロダクト開発 - Vercel AI SDK を観察して AI Agent と仲良くなろう! #FEC余熱NIGHT
izumin5210
3
490
Swift Concurrency - 状態監視の罠
objectiveaudio
2
490
どの様にAIエージェントと 協業すべきだったのか?
takefumiyoshii
2
640
Web Components で実現する Hotwire とフロントエンドフレームワークの橋渡し / Bridging with Web Components
da1chi
3
2k
アメ車でサンノゼを走ってきたよ!
s_shimotori
0
210
階層構造を表現するデータ構造とリファクタリング 〜1年で10倍成長したプロダクトの変化と課題〜
yuhisatoxxx
3
970
Model Pollution
hschwentner
1
190
Le côté obscur des IA génératives
pascallemerrer
0
140
Featured
See All Featured
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
9
590
Gamification - CAS2011
davidbonilla
81
5.5k
Art, The Web, and Tiny UX
lynnandtonic
303
21k
A better future with KSS
kneath
239
18k
Building Flexible Design Systems
yeseniaperezcruz
329
39k
Keith and Marios Guide to Fast Websites
keithpitt
411
23k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
140
34k
GitHub's CSS Performance
jonrohan
1032
470k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
1.6k
Build your cross-platform service in a week with App Engine
jlugia
232
18k
Side Projects
sachag
455
43k
Speed Design
sergeychernyshev
32
1.1k
Transcript
Gradle Dive: Writing Custom Plugins Theophilus Kibet Android Engineer @Kyosk
@_kibetheophilus
:app
:app :feature:profile :feature:cart :feature:products :data:local :data:network :core
26+
- Each module needs a build.gradle.
- Each module needs a build.gradle. - Duplicate scripts in
each module.
- Each module needs a build.gradle. - Duplicate scripts in
each module. - Hard to maintain.
- Each module needs a build.gradle - Duplicate scripts in
each module - Hard to maintain e.g creating a build type
- Declares Gradle plugins. Each build.gradle
- Declares Gradle plugins. - Sets build parameters. Each build.gradle
- Declares Gradle plugins. - Sets build parameters. - Declares
dependencies. Each build.gradle
Gradle Plugin
- packages up reusable pieces of build logic, which can
be used across many different projects and builds. Gradle Plugin
- Script Plugin Types of Plugins
- Script Plugin - Binary Plugin Types of Plugins
- Additional build script Script Plugin
- Additional build script - apply from : “flavors.gradle” Script
Plugin
- Written by implementing plugin interface. Binary Plugin
- Written by implementing plugin interface - Applied using a
unique id Binary Plugin
- Written by implementing plugin interface - Applied using a
unique id - plugins { id(“com.android.library”) } Binary Plugin
- What will the plugin do? Creating a Plugin
- Add gradleApi() and kotlin dependencies Setup
None
- Add gradleApi() and kotlin dependencies - Create a class
implementing Plugin interface Setup
None
None
None
None
None
- Share build logic across modules - Reduced build script
size - Migrate all our files to kts Benefits
Questions?
Thank you!