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
給忙碌開發者的Android開發流程自動化簡介
Search
Elvis Lin
October 15, 2016
Programming
18
3.1k
給忙碌開發者的Android開發流程自動化簡介
簡介開發者為什麼需要 Continuous Integration,以及在 Android 開發上需要實踐 Continuous Integration 的基本步驟 #JCConf2016
Elvis Lin
October 15, 2016
Tweet
Share
More Decks by Elvis Lin
See All by Elvis Lin
Protect Users' Privacy in iOS 14
elvismetaphor
0
46
Dubugging Tips and Tricks for iOS development
elvismetaphor
0
48
Strategies of Facebook LightSpeed project
elvismetaphor
0
63
Background Execution And WorkManager
elvismetaphor
2
480
作為一個跨平台的 Mobile App 開發者,從入門到放棄!?
elvismetaphor
2
480
Dependency Injection for testability of iOS app
elvismetaphor
1
1.4k
Briefly Introduction of Kotlin coroutines
elvismetaphor
1
270
MotionLayout Brief Introduction
elvismetaphor
1
320
Chapter 10. Pattern Matching with Regular Expressions
elvismetaphor
0
38
Other Decks in Programming
See All in Programming
Webエンジニア主体のモバイルチームの 生産性を高く保つためにやったこと
igreenwood
0
330
たのしいparse.y
ydah
3
120
これが俺の”自分戦略” プロセスを楽しんでいこう! - Developers CAREER Boost 2024
niftycorp
PRO
0
190
Beyond ORM
77web
5
650
Effective Signals in Angular 19+: Rules and Helpers @ngbe2024
manfredsteyer
PRO
0
130
create_tableをしただけなのに〜囚われのuuid編〜
daisukeshinoku
0
240
선언형 UI에서의 상태관리
l2hyunwoo
0
160
17年周年のWebアプリケーションにTanStack Queryを導入する / Implementing TanStack Query in a 17th Anniversary Web Application
saitolume
0
250
Semantic Kernelのネイティブプラグインで知識拡張をしてみる
tomokusaba
0
180
StarlingMonkeyを触ってみた話 - 2024冬
syumai
3
270
今年一番支援させていただいたのは認証系サービスでした
satoshi256kbyte
1
250
あれやってみてー駆動から成長を加速させる / areyattemite-driven
nashiusagi
1
200
Featured
See All Featured
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
0
98
Imperfection Machines: The Place of Print at Facebook
scottboms
266
13k
KATA
mclloyd
29
14k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
665
120k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
251
21k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
520
Optimizing for Happiness
mojombo
376
70k
Transcript
妔盜繓樄咳ᘏጱ Android樄咳窕纷ᛔ㵕玕墋Օ Elvis Lin 2016/10/15
Agenda • 樄咳ᘏૡ֢碻䨝蝽کጱࢯ櫞 • 瞱媲褸౮ҁContinuous Integration҂101 • 禊蝄ℂ樄咳牏翥捌牏介手牏۱ጱ螂纷Ӿ牧ݱ圵ݢ 犥ֵአጱૡٍ蚤ᒽኼ •
ٌ犢ፘ橕ጱૡٍ
About Me Elvis Lin Mobile Application Developer • Github: https://github.com/elvismetaphor
• Blog: http://blog.elvismetaphor.me
盜繓樄咳ᘏጱӞॠ • 狕硬纷ୗҁࢩ傶憒໒݈虋ԧ҂ • 翥捌०硻ҁࢩ傶֦㴄㴄狕硬ԧ纷ୗ҂ • ತ BUGҁࢩ傶֦㴄㴄狕硬ԧ纷ୗ҂ • ᯿蕦Ӥ蝄㵕֢
• 奰ෝݢ犥樄ত䌃碝ۑ胼ԧ • ۑ胼䌃کӞ聲樿统簁ᥝ姴盪ڊӞ㮆粚 • ꔇꔇ
䌃嘨综ӣդ牧瞟恝藮Ӟኞ!?
樄咳ᘏጱ෭ଉ 憒㴟 樄咳 ୌᗝ 介手 咳㬙 粚ᓕቘ Issue Tracking 翥捌
戔ਧ
樄咳ᘏጱࢯह • ℂڡত䯤మک叨ߝ۱咳㬙ጱ窕纷盄裾 • Ԫ眐ፘ吚ጱ耆卓 • 樄咳ᘏጱԆᥝ犨率䛑扗ฎ樄咳碝ۑ胼
But, 蝡ฎӞ㮆 Bot ጱ碻դ
䛑扗珿አૡٍ 褔犵樄咳ᘏጱ揗砾
https://www.jitbit.com/alexblog/249-now-thats-what-i-call-a-hacker/
Every time they got a problem they found that they
were still repeating what they were doing. They would write a tool for it, automate it. — Edmond Lau
瞱媲碉ݳҁCI҂
https://insights.sei.cmu.edu/devops/2015/01/continuous-integration-in-devops-1.html
樄咳
ૡཿ珿ٌԪ牧ضڥٌ瑊
珿አ Android Studio • ԧ薹ଉአጱ盠ഠ棎 • 狕硬戔ਧ䲆䔶玕樄咳絑ह • 㶓ڊ戔ਧ䲆 •
疥戔ਧ䲆硯獈粚ᓕቘ羬翄
None
㶓獈膏㶓ڊSettings
粚矒ګ
Git • 獤碂ୗጱ粚矒ګ羬翄 • Gitlab — ࣁᛔ૩ጱԆ秚Ӥ礍戔 Git Server •
GitHub — 娄Ӥጱܻত嘨դᓕ๐率
GitHub • 纷ୗ嘨ጱ粚ᓕቘ • կ物۱ೡᛔ㵕ኞ౮ጱ牏䟖አ觊Markdown承ጱREADME 䲆礯 • 㺔氂蝍擽羬翄ҁݶ碻ݢአෝۑ胼襑穩҂ • Wiki
• 犨率ڜ蔭 • ኚ粬瑽
Zenhub 疥 Github Issues 犥̿፡礂̀ොୗ ᓕቘ
None
None
None
瞱媲碉ݳ๐率
ଉ憎ጱ瞱媲碉ݳ๐率 • Jenkins — ࣁᛔ૩ጱԆ秚Ӥ礍戔瞱媲碉ݳ֑๐瑊 • Travis CI — 娄Ӥጱ瞱媲碉ݳ֑๐瑊ҁ犖磪㻌秚粚҂
Jenkins • ݢ犥ਧ碻礬硁粬ਧ礿կጱ藉咳㬵䁆ᤈ粬ਧጱ犨率 • ᛔ㵕玕翥捌膏介手ጱ㵕֢ • 磪战ग़ plugins ݢ犥蚤ٌ犢๐率Ӟݶֵአ •
磪 Web ጱ瑽୵玕戔ਧՕᶎ
Travis CI
ࣁ Travis CI 翥捌 Android
ୌᗝ/翥捌
Gradle • ℂ Command Line ک IDE ک CI Server
᮷磪ඪൔ • Groovy Script (चෝ Groovy 戔懯ጱ DSL) • Product Flavour • Powerful Dependencies Management
ࣁ犤ڜ翥捌 Android • Windows > gradlew.bat assembleDebug • Mac $
chmod +x gradlew $ ./gradlew assembleDebug • 䁆ᤈᛔ懪ጱ犨率 $ ./gradlew tasks
介手
FIRST • Fast • Independant • Repeatable • Self Validation
• Timely
The AAA Pattern • Arrange • Act • Assert
ଉአጱ介手 Library • JUnit 4 • Android Test Support Library
• Robolectric • Espresso • Mockito
JUnit • 㻌ز介手 • ݝ胼朼䌘奈 Java ጱ API
Android Testing Support Library • ׀ Android API ጱ介手 •
襑ᥝࣁ䋿誢秚瑊秇硈瑊Ӥ䁆ᤈ
Robolectric • 䁆ᤈ Android API ፘ橕ጱ㻌ز介手ࣁ襎脲Ӥ • 䁆ᤈ蝧ଶ斃盠
Espresso • UI 介手ጱૡٍ • ݢ犥奾ݳ Cucumber 䁆ᤈ涢硩介手
Mockito • Mock Framework
Clean Architecture https://8thlight.com/blog/uncle-bob/2012/08/13/the-clean-architecture.html
CleanӞ膢ฎ瞲牧դ嘨犥၇莡ጱ୵制狅硁 Ӟਧጱ狅蚅憒㳷ᤩ㴟獤傶ग़䍅物獉䍅䌘ෝ क़䍅Ӟ篷ಅᎣ牐蝡疰ޱ茐狅蚅ݝ胼ኧक़ ݻ獉牐
咳㬙
Grade Play Publisher Plugin • Ӟ㮆 Gradle ጱ plugin牧翥捌螂纷碉ݳ臑অ •
虏 APK Ӥ㯽ک Google Play ጱ螂纷ݢ犥㷢碍玕
Crashlytic • 痀ෝ Fabric Mobile Development Kits ጱӞ蟂犩 • 蝍擽ֵአᘏ咳ኞጱ梊藮
• 叨ኞ梊藮䁭ޞ • 朼䌘犋ݶጱ秚ࣳ牏碻樌牏纷ୗ嘨֖ᗝ֢ڊ獤觊
None
者奾 • Ӟ㮆叨ߝکᥝݢ犥咳㬙妔ֵአᘏԏ獮牧ᛗ۱珀樄咳牏 ୌᗝ/翥捌牏介手ጱ㵕֢ • ᛔ㵕玕覍໐ஞጱૡ֢牧䌕ဳ樄咳ۑ胼 • 脻玕ྯ㮆㵕֢牧虏犋ݶጱ樄咳Ո㹓ݢ犥وՁፘݶጱ 戔ਧ
㷢ᘍ䨗罕
氎ܻێ纷ୗԏᐟ 膏֦ݶࣁ