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
fastlaneはともだち こわくないよ
Search
rikusouda
August 22, 2017
1
950
fastlaneはともだち こわくないよ
rikusouda
August 22, 2017
Tweet
Share
More Decks by rikusouda
See All by rikusouda
Swiftのスタック変数とCPUレジスタの関係を読み解いた
rikusouda
2
2.2k
SwiftとCPUレジスタ
rikusouda
2
610
OSSを育てながらiOSアプリでパンくずリストを実現した
rikusouda
2
5k
Featured
See All Featured
Scaling GitHub
holman
458
140k
Why Our Code Smells
bkeepers
PRO
334
57k
10 Git Anti Patterns You Should be Aware of
lemiorhan
654
59k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Building Applications with DynamoDB
mza
90
6.1k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
8
860
GraphQLの誤解/rethinking-graphql
sonatard
67
10k
The Art of Programming - Codeland 2020
erikaheidi
52
13k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
Bash Introduction
62gerente
608
210k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
42
9.2k
Designing on Purpose - Digital PM Summit 2013
jponch
115
7k
Transcript
FASTLANEͱͩͪ ͜Θ͘ͳ͍Α fastlaneษڧձ vol4 @rikusouda
INTRODUCTION ࣗݾհ ▸ @rikusoua ▸ iOSΞϓϦΤϯδχΞ ▸ νϟοτͷձࣾͰಇ͍͍ͯΔ ▸ νϟοτΞϓϦͷ։ൃ
▸ ༷ʑͳܗଶͷϦϦʔεΛ࣮ݱ(In-House, VPP Custom B2B) ▸ fastlaneϨϕϧ : NEW GAME! Ͱݴ͏ͱ੨༿ͪΌΜ͘Β͍
AGENDERS ࠓ͢͜ͱ ▸ fastlaneා͍ˠfastlaneා͘ͳ͍ ▸ fastlaneΛ͓͔ͬͨ͛Ͱָʹͳͬͨ ▸ CIڥಋೖͷࣗຫۤ࿑
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ FASTLANEͱग़ձͬͨͱ͖ͷRIKUSOUDA ▸ Rubyͬͨ͜ͱݟͨ͜ͱͳ͍ ▸ ϞόΠϧΞϓϦ։ൃະܦݧ ▸ ͋ΔಥવiOSΤϯδχΞͱͯ͠σϏϡʔͨ͠ ▸ લऀ͔ΒҾ͖ܧ͗Λड͚ͨ
ࣾ৴ “fastlane iOS beta"ͰͰ͖Δ͔Β લऀɹ FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ
Θ͔Βͳ͍
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ FASTLANEͱͷग़ձ͍ ▸ ʮfastlane ios betaʯͱ͍͏ίϚϯυΛڭ͑ͯ͘Ε͚ͨͩ ▸ ࣗྗͰFastfileΛݟ͚ͭͯ։͍ͯΈ͚ͨͲͳʹ͕ॻ͍͍ͯΔ ͷ͔Θ͔ΒͣΑ͘Θ͔Βͳ͍ڪාײ ▸
͔͍ͭ͜ͳͤΔͱศརͦ͏ͩͳͱࢥͬͨ ▸ ͦͷ··͠Β͘FastfileΛ৮Δ͜ͱͳ͘ɺϏϧυͷ࣌ʹί ϚϯυΛୟ͚ͩͩͬͨ͘
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ ࣍ʑͱ૿͍͑ͯ͘ϦϦʔεཁٻ ▸ ͓٬༷ͷApple Developer Enterprise ProgramͰ͓٬༷ͷ ࣾʹ৴͍ͨ͠ ▸ VPP
Custom B2BͰಛఆͷ͓٬༷ʹ͚ͩΧελϜ൛Λ৴͠ ͍ͨ ▸ ։ൃதػೳΛ֬ೝ͢ΔͨΊͷΞϓϦཉ͍͠(ຊ൪Staging ʹͭͳ͙ΞϓϦͱผʹ)
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ FASTLANEษڧձʹࢀՃͯ͠Έͨ ▸ Βͳ͍׆༻ํ๏actionͷͳͲ͕ग़͖ͯͯௐΔ͖͔ͬ ͚ʹͳͬͨ ▸ SlackʹࢀՃͯ͠ओ࠵ऀͷํʑͷൃݴ͕ܹʹͳͬͨ ▸ ͚͕͍ࣗͩํͰ໎͍ͬͯΔ༁Ͱͳ͍ͱͬͯมͳযΓ ͕ͳ͘ͳͬͨ
▸ ͳΜ͔ΈΜͳRubyͰ͖ΔͬΆ͍
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ RUBYͷจ๏Λ͋Δఔ֮͑ͨ ▸ FastfileͬͯRubyͷDSLͱΒΒ͍͠ ▸ Ruby͕ͳΜͱͳ͘Θ͔Δ͜ͱͰɺFastfileΛฤू͢Δ͜ͱ ͷڪා͕ࠀ͞Εͨ ▸ fastlaneࣗମRubyͰ࣮͞Ε͍ͯΔ
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ ެࣜυΩϡϝϯτΛಡΜͩ ▸ https://docs.fastlane.tools/ ▸ https://github.com/fastlane/docs ▸ ͍ํͷྫActionҰཡͳͲ ▸ ͲΜͳ͜ͱ͕Ͱ͖Δͷ͔ΠϝʔδͰ͖ΔΑ͏ʹͳͬͨ
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ FASTLANEͷιʔεΛಡΜͰΈͨ ▸ ͨͱ͑ɺupdate_app_identifierͬͯ Action xcodeproj มߋ͢ Δ͔ Into.plistมߋ͢Δͷ͔Α͘Θ͔Βͣɺ͏ͷ͕ͳΜͱͳ͘ා͍
▸ ͻͱ·ͣfastlaneͷϦϙδτϦΛaction໊Ͱݕࡧ͢Δͱग़͖ͯͨ ▸ https://github.com/fastlane/fastlane/blob/master/fastlane/lib/ fastlane/actions/update_app_identifier.rb ▸ ಡΜͰΈΔͱׂͱΘ͔Γ͍͢ ▸ த͕Θ͔Δͱ͏͜ͱͷڪා͕ബΕ͖ͯͨ
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ TYPOݟ͚ͭͨͷͰCONTRIBUTEͯ͠Έͨ
FASTLANE͕ා͘ͳ͘ͳΔ·Ͱ EXPLITLY -> EXPLICITLY
None
AGENDERS ͍·͍ͯ͠Δͱ͜Ζ ▸ fastlaneා͍ˠfastlaneා͘ͳ͍ ▸ fastlaneΛ͓͔ͬͨ͛Ͱָʹͳͬͨ ←࣍͜͜ ▸ CIڥಋೖͷۤ࿑
FASTLANEΛ͓͔ͬͨ͛Ͱָʹͳͬͨ ABOUT OUR CHAT APP ▸ Ϗδωενϟοτ(ݸਓͰͳ͘ձࣾͰ͏) ▸ Enterprise൛ͱ͍͏ΦϯϓϨϛε൛(Ϋϥυ͡Όͳ͍൛)͕͋Δ ▸
༷ʑͳΞϓϦܗଶ͕ߟ͑ΒΕΔ ▸ ADEPͷIn-House (ADEP: Apple Developer Enterprise Program) ▸ VPP Custom B2B (VPP: Volume Purchase Program) ▸ App Store ▸ ࣾ৴ ( Fabric Beta )
FASTLANEΛ͓͔ͬͨ͛Ͱָʹͳͬͨ VPP CUSTOM B2Bͷۤɹɹ ▸ ΧελϜ༰͕มΘΔͨͼʹผΞϓϦͱͯ͠iTunes Connectͷొ͕ ඞཁ ▸ ฐࣾͷ߹ΞϓϦόʔδϣϯΛސ٬͝ͱʹݻఆ͍ͨ͠(αʔόʔͱͦΖ
͑ΔͨΊʹ) ▸ ୯७ʹΔͱXcodeͰSchemeTargetΛ૿͢͜ͱʹͳΓ͔Ͷͳ͍(Ξ ϓϦ͕૿͑Δͱഁ͢Δ) ▸ iTunes ConnectͰԿࣅͨΑ͏ͳใΛ܁Γฦ͠ొ͢Δ͜ͱʹͳ Δ
FASTLANEΛ͓͔ͬͨ͛Ͱָʹͳͬͨ FASTLANEͰָͰ͖͍ͯΔ෦ ▸ App Bundle IdentifierDisplay NameͷҰ࣌తͳॻ͖͑ ▸ iTunes Connect༻ͷϝλσʔλɺScreen
Captureཧ
FASTLANEΛ͓͔ͬͨ͛Ͱָʹͳͬͨ APP BUNDLE IDENTIFIERDISPLAY NAMEͷҰ࣌తͳॻ͖͑ ▸ SchemeTargetΛ૿ͣ͞ʹόϦΤʔγϣϯΛ૿ͤΔ
FASTLANEΛ͓͔ͬͨ͛Ͱָʹͳͬͨ ITUNES CONNECT༻ͷϝλσʔλɺSCREEN CAPTUREཧ ▸ fastlane/metadata͕͋Ε deliver actionϩʔΧϧͷϝλ σʔλ Screen
CaptureΛiTunes Connectʹొ͢Δ ▸ VPP Custom B2B༻ʹࣅͨΑ͏ͳΞϓϦΛ૿͢ͱ͖͜ͷ ΈΛͬͯखಈొΛ͠ͳ͍͜ͱͰָΛ͢Δ ▸ name.txt(App Storeʹొ͢ΔΞϓϦ໊)আ͓ͯ͘͠ͱ ָ͔
None
AGENDERS ͍·͍ͯ͠Δͱ͜Ζ ▸ fastlaneා͍ˠfastlaneා͘ͳ͍ ▸ fastlaneΛ͓͔ͬͨ͛Ͱָʹͳͬͨ ▸ CIڥಋೖͷۤ࿑ ←࣍͜͜
CIڥಋೖͷۤ࿑ CIڥಋೖ͠·ͨ͠ ▸ Bitriseͷ༗ྉϓϥϯ(ಉ࣮࣌ߦ2ͭ)Λܖ ▸ git push͢Δ͝ͱʹςετΛ࣮ߦ(GitHub࿈ܞ) ▸ ࣾ৴ϦϦʔε࣌ͷϏϧυΛ։ൃऀͷPCͰߦΘͳͯ͘ Α͘ͳͬͨ
▸ fastlane͍ͬͯΔͷͰCIଆͷઃఆগͳ͍
None
CIڥಋೖͷۤ࿑ ۚͷؙൃಈ·Ͱͷಓ ▸ ࣾ৴ϦϦʔεͷͨΊͷϏϧυΛ։ൃऀͷPCͰߦ͏͜ ͱوॏͳΛແବʹ͢Δߦҝ ▸ CIڥΛಋೖ͢Δ͜ͱͰɺϏϧυͷΛແବʹͤͣຊདྷ ͷ։ൃʹճ͢͜ͱ͕Ͱ͖Δ ▸ ࣦΘΕ͍ͯΔͰ͋Ζ͏Λֹۚʹࢉ͠ɺCIڥ༗ྉϓϥ
ϯͷֹۚͱൺֱͯ͠ΈΔ
CIڥಋೖͷۤ࿑ CIڥಋೖͰۤ࿑ͨ͜͠ͱ ▸ Apple IDͷύεϫʔυͲ͏͢Δ? ▸ certmatchΛ͍ͬͯͳ͍͚Ͳূ໌ॻ? ▸ CIڥͰ͚ͩΤϥʔʹͳΔέʔεʹૺ۰ ▸
gymͰॺ໊ؔ࿈ͰΤϥʔʹͳͬͨ ▸ scan͕ͳ్͔ͥதͰࣦഊ
CIڥಋೖͷۤ࿑ APPLE IDͷύεϫʔυͲ͏͢Δ? ▸ FASTLANE_PASSWORD ڥมʹύεϫʔυΛઃఆ
CIڥಋೖͷۤ࿑ CERTMATCHΛ͍ͬͯͳ͍͚Ͳূ໌ॻ? ▸ BitriseͳΒূ໌ॻΛ؆୯ʹڥʹөͰ͖Δ(ͪΐͬͱ͚ͩ Bitriseґଘͯ͠͠·ͬͨՕॴ)
CIڥಋೖͷۤ࿑ GYMͰॺ໊ؔ࿈ͰΤϥʔʹͳͬͨ ▸ Xcode7ͷઃఆΛͦͷ··͍ͬͯͨ ▸ Automatic Code SigningΛҰ࣌తʹແޮʹ͢Δ͜ͱͰղܾ
CIڥಋೖͷۤ࿑ SCAN͕ͳ్͔ͥதͰࣦഊ ▸ ݕࡧ͢Δͱ͍Ζ͍Ζग़Δ͕ͲΕΛͬͯղܾͤͣ ▸ Ϗϧυઃఆ͕ؒҧ͍ͬͯͨͷͰमਖ਼͢Δͱޭ͢ΔΑ͏ʹ
·ͱΊ ·ͱΊ ▸ ࠷ॳfastlane৮Δͷා͔͚ͬͨͲɺΘ͔ͬͯ͘Δͱා͘ͳ ͘ͳ͖ͬͯͨ ▸ fastlaneͷ͓͔͛ͰVPP Custom B2BΞϓϦͷͨΊʹ SchemeTargetΛ૿͢͜ͱΛճආͰ͖ͨ
▸ CIڥಋೖ͢ΔͱͤʹͳΕΔɻͭ·͍ͮͨࣄྫͷڞ༗
͝੩ௌ ͋Γ͕ͱ͏͍͟͝·ͨ͠