Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Carthageを使ってみて自作ライブラリにも適用してみた話
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Kohei Tabata
July 22, 2016
Programming
810
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Carthageを使ってみて自作ライブラリにも適用してみた話
Kohei Tabata
July 22, 2016
More Decks by Kohei Tabata
See All by Kohei Tabata
AIと協業する開発の進め方
nerd0geek1
0
190
営業活動なしで継続的に案件を受注する方法 / how to get a contract without sales as a freelance
nerd0geek1
2
1k
生体データを取り扱うアプリ開発の勘所
nerd0geek1
1
160
動線改善とステータス可視化で家庭内のストレスを軽減した話
nerd0geek1
3
4.6k
家庭をプロジェクトとして運営した話
nerd0geek1
2
4.4k
fastlaneの勉強会を主催して学んだこと、得たこと、悩んだこと
nerd0geek1
1
1.3k
みんなで育てるprecheck
nerd0geek1
1
870
matchとは?match導入のメリット
nerd0geek1
4
650
Improve your workflow with Sketch plugin
nerd0geek1
3
1.6k
Other Decks in Programming
See All in Programming
カツオ、ご期待ください
suneo3476
0
190
TechTown - Creating Composable Callables in Contemporary C++
rollbear
0
130
外から家のPCの電源入れたい!をPHPで解決する
kawashimo0
1
130
UnityでSystem.Net.WebSocketsなWebSocketサーバが動かないのでUnity Monoのコードを覗いてみた / about implementing websocket server with unity mono
drumath2237
1
610
Next.js: The final boss of Web Performance
guaca
0
250
コードで差別化できない時代の ソフトウェアエンジニアリング / Software Engineering in an Era Where Code Doesn’t Differentiate
kishida
2
180
作って学ぶSpring BootのAuto Configuration / JJUG Night Seminar 2026-10-19
rshindo
0
140
Railsバージョンを4倍にした話
optim
0
350
Web Framework Benchmark Battle 2026, Any%
a_matsuda
2
2k
FactoryBotをやめればRSpecは速くなるのか?
yuta_onishi_97
0
290
Long Living Tokens, Die, Die, Die! (or: The One Ring is Banned in Modern)
sylph01
0
300
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
180
Featured
See All Featured
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
320
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
4
4.4k
Practical Orchestrator
shlominoach
192
12k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
33
5.2k
What the history of the web can teach us about the future of AI
inesmontani
PRO
2
740
The Illustrated Children's Guide to Kubernetes
chrisshort
51
53k
Highjacked: Video Game Concept Design
rkendrick25
PRO
1
480
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
600
The SEO Collaboration Effect
kristinabergwall1
1
590
Color Theory Basics | Prateek | Gurzu
gurzu
1
490
Transcript
Carthageを使ってみて 自作ライブラリにも適用してみた話 2016/07/22 Retty Tech Cafe@Retty
自己紹介 ・Kohei Tabata(@nerd0geek1) ・iOS/Mac/tvOS Developer ・Saib Studio LLC ・Fastlane大好き ・最近はBLEと仲良し。
Saib Studio LLC Kohei Tabata
Next! Remote ・LT/プレゼン用iOS・Macアプリ ・iOSアプリからMacのスライドを操作可能 ・便利なタイマー機能付き! Macアプリはこちら http://saib-stud.io/Next_Installer.pkg
目次 ・CocoaPodsとCarthageの違い ・Carthageのプロジェクトへの導入 ・Carthageの自作ライブラリへの適用
Carthage使ってますか?
CocoaPods vs Carthage
CocoaPods ・rubyで書かれたパッケージマネージャー ・Objective-C/Swiftライブラリが対象 ・iOS4以上(Swiftライブラリを使う場合はiOS8以上)で利用可能 ・ライブラリはプロジェクトのビルド時にコンパイルされる。
Carthage ・Swiftで書かれたパッケージマネージャー ・Objective-C/Swiftライブラリが対象 (Objective-Cも使える、とご指摘くださった@ikesyoさん、ありがとうございます。) ・iOS8以上で利用可能 ・frameworkをビルドし、プロジェクトに取り込む
Carthageのプロジェクトへの導入
Swiftがまだ1.x系だった頃…
None
ビルド速度改善のために導入 (+static libraryとuse_frameworks!同時に使えなかったため)
Cartfile
carthageコマンド carthage update --platform iOS platform指定の理由は以下の2つ ・ビルド時間短縮のため(デフォルトでは全platformが対象となる) ・iOS以外のplatformを対象としたビルドでコケることが多いため
時間短縮に役立ってくれた (SnapKitだけコケる、ということもたまにありますが)
ライブラリの作成とCarthage対応
ライブラリの作成 ・同時並行で抱えているプロジェクトが多い (常駐先1-2、自社2、個人2-3) ・似たような機能を実装することが多い ・ライブラリ化して使いまわしたい欲求 ・インターフェイス分離の原則に従った設計を行うために、 実験的にライブラリ化したい
ライブラリの作成 ・実装者が2人以上いる場合はREADME.mdを用意 ・ただ、場合によってはリリースを優先してREADMEなどは 後から追加したい場合がある
CocoaPodsの場合 ・.podspecの作成 ・README.mdの作成 ・サンプルプロジェクトの作成 ・CocoaPodsへの登録 などなどやることが多い。
Carthageの場合 ・Build SchemeをShared Schemeに変更する のみ。
まとめ ・Carthageはビルド時間の短縮に良い ・Swiftでライブラリをカジュアルに作って使う、という 最初の一歩が踏み出しやすい
ご静聴ありがとうございました
参考 • メッセージングアプリSync開発の舞台裏(iOS) (http://engineer.wantedly.com/2015/09/09/sync-messenger-ios-project.html) • Carthage/Carthage (https://github.com/Carthage/Carthage) • CocoaPods/CocoaPods (https://github.com/CocoaPods/CocoaPods)