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
ローカルのグローバル環境を可能な限り汚染しないXcodeの開発環境構築
Search
Yu Sugawara
October 27, 2021
Programming
0
67
ローカルのグローバル環境を可能な限り汚染しないXcodeの開発環境構築
グローバル環境を可能な限り汚染しないXcodeの開発環境構築
Yu Sugawara
October 27, 2021
Tweet
Share
More Decks by Yu Sugawara
See All by Yu Sugawara
HIG の歴史
yusuga
1
35
誰でも簡単に組版した PDF を生成する仕組みづくり
yusuga
1
72
WWDC 2023 現地参加報告(コード編)
yusuga
0
140
マイク環境を考える
yusuga
0
32
Custom AppをIP制限ありのままで審査に通す方法
yusuga
0
5.4k
Swiftのas Any / AnyObjectの暗黙的な型変換について
yusuga
2
1.6k
Pure DI 101
yusuga
0
210
Final conclusion of the iOS architecture
yusuga
0
270
Practical application of ReactorKit
yusuga
1
360
Other Decks in Programming
See All in Programming
3 Effective Rules for Using Signals in Angular
manfredsteyer
PRO
1
100
エンジニアとして関わる要件と仕様(公開用)
murabayashi
0
290
Flutterを言い訳にしない!アプリの使い心地改善テクニック5選🔥
kno3a87
1
180
Webの技術スタックで マルチプラットフォームアプリ開発を可能にするElixirDesktopの紹介
thehaigo
2
1k
ふかぼれ!CSSセレクターモジュール / Fukabore! CSS Selectors Module
petamoriken
0
150
とにかくAWS GameDay!AWSは世界の共通言語! / Anyway, AWS GameDay! AWS is the world's lingua franca!
seike460
PRO
1
860
Nurturing OpenJDK distribution: Eclipse Temurin Success History and plan
ivargrimstad
0
900
色々なIaCツールを実際に触って比較してみる
iriikeita
0
330
最新TCAキャッチアップ
0si43
0
140
ヤプリ新卒SREの オンボーディング
masaki12
0
130
CSC509 Lecture 09
javiergs
PRO
0
140
EventSourcingの理想と現実
wenas
6
2.3k
Featured
See All Featured
Being A Developer After 40
akosma
86
590k
The Cost Of JavaScript in 2023
addyosmani
45
6.7k
Build The Right Thing And Hit Your Dates
maggiecrowley
33
2.4k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
38
1.8k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
31
2.7k
Site-Speed That Sticks
csswizardry
0
25
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
410
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Building a Modern Day E-commerce SEO Strategy
aleyda
38
6.9k
How to Think Like a Performance Engineer
csswizardry
20
1.1k
How GitHub (no longer) Works
holman
310
140k
Transcript
ϩʔΧϧڥΛՄೳͳݶΓԚછ͠ͳ͍ Xcodeͷ։ൃڥߏங TechLab LTձ #̍ 2021-03-31 1
ੁݪ ༞ @yusuga_ 2
ڥߏஙͬͯͲ͏ͯ͠·͢ʁ 3
ڥߏஙͬͯͲ͏ͯ͠·͢ʁ • Carthage 3
ڥߏஙͬͯͲ͏ͯ͠·͢ʁ • Carthage • CocoaPods 3
ڥߏஙͬͯͲ͏ͯ͠·͢ʁ • Carthage • CocoaPods • xcodegen 3
ڥߏஙͬͯͲ͏ͯ͠·͢ʁ • Carthage • CocoaPods • xcodegen • swiftgen 3
ڥߏஙͬͯͲ͏ͯ͠·͢ʁ • Carthage • CocoaPods • xcodegen • swiftgen •
swiftlint 3
νʔϜ։ൃͰͷࠔΓ͝ͱ 4
ݪҼ 5
ݪҼ • ֤ʑͷڥʹΠϯετʔϧͯ͋͠Δπʔϧʹόʔδϣϯͷࠩҟ ͕͋Δ 5
ݪҼ • ֤ʑͷڥʹΠϯετʔϧͯ͋͠Δπʔϧʹόʔδϣϯͷࠩҟ ͕͋Δ • READMEʹʑͱڥߏஙखॱΛॻ͘ͷπϥΠ 5
ݪҼ • ֤ʑͷڥʹΠϯετʔϧͯ͋͠Δπʔϧʹόʔδϣϯͷࠩҟ ͕͋Δ • READMEʹʑͱڥߏஙखॱΛॻ͘ͷπϥΠ • ڥߏங͕Ͱ͖ͳ͍ͱ͍͏͍߹Θ͕ͤདྷΔͷπϥ͍ 5
ݪҼ • ֤ʑͷڥʹΠϯετʔϧͯ͋͠Δπʔϧʹόʔδϣϯͷࠩҟ ͕͋Δ • READMEʹʑͱڥߏஙखॱΛॻ͘ͷπϥΠ • ڥߏங͕Ͱ͖ͳ͍ͱ͍͏͍߹Θ͕ͤདྷΔͷπϥ͍ • lockϑΝΠϧͷࠩͳͲɺؾʹ͠ͳ͍ਓؾʹͤͣcommit͢Δ
ͷ͕πϥ͍ 5
ղܾํ๏ 6
ղܾํ๏ • ՄೳͳݶΓϩʔΧϧڥΛԚછ͠ͳ͍Ͱ֤छڥߏஙπʔϧΛ ༻͢Δ 6
ղܾํ๏ • ՄೳͳݶΓϩʔΧϧڥΛԚછ͠ͳ͍Ͱ֤छڥߏஙπʔϧΛ ༻͢Δ • makeϑΝΠϧΛλεΫϥϯφʔͱͯ͠༻͠ɺڥߏஙΛߦ͏ 6
ඪ Homebrew └─ Mint ├─ Carthage ├─ xcodegen ├─ swiftgen
└─ swiftlint bundler └─ CocoaPods 7
Homebrew • macOSͷύοέʔδϚωʔδϟ ❯ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/ Homebrew/install/master/install.sh)"
8
Homebrew • Homebrewܦ༝ͰΠϯετʔϧ͍ͨ͠πʔϧΛهड़ͨ͠Brewfile Λ༻ҙ brew "mint" 9
Homebrew • BrewfileͷπʔϧΛΠϯετʔϧ ❯ brew bundle --no-upgrade --no-lock 10
Homebrew • πʔϧؒͷґଘؔ Homebrew └─ Mint 11
Mint • SwiftͷπʔϧͷύοέʔδϚωʔδϟ • mintܦ༝ͰΠϯετʔϧ͍ͨ͠πʔϧΛهड़ͨ͠MintfileΛ༻ҙ carthage/
[email protected]
yonaskolb/
[email protected]
swiftgen/
[email protected]
realm/
[email protected]
12
Mint • MintfileͷπʔϧΛΠϯετʔϧ ❯ mint bootstrap 13
Mint • πʔϧؒͷґଘؔ Homebrew └─ Mint ├─ Carthage ├─ xcodegen
├─ swiftgen └─ swiftlint 14
bundler • gemͷόʔδϣϯͱґଘؔཧπʔϧ1 ❯ gem install bundler 1 όʔδϣϯࢦఆͰͷΠϯετʔϧ: gem
install bundler:2.0.2 15
bundler • bundlerܦ༝ͰΠϯετʔϧ͍ͨ͠πʔϧΛهड़ͨ͠GemfileΛ ༻ҙ source 'https://rubygems.org' gem 'cocoapods' 16
bundler • GemfileͷπʔϧΛΠϯετʔϧ2 ❯ bundle install --path vendor/bundle 2 --path
ඇਪͳͷͰɺΑΓਖ਼͘͠Δ߹ .bundle/config Λ༻ҙ 17
bundler • πʔϧؒͷґଘؔ Homebrew └─ Mint ├─ Carthage ├─ xcodegen
├─ swiftgen └─ swiftlint bundler └─ CocoaPods 18
ڥߏஙํ๏ 19
ڥߏஙํ๏ • MakefileΛ༻ҙ 19
ڥߏஙํ๏ • MakefileΛ༻ҙ • γΣϧεΫϦϓτΛ༻ҙ͍ͯͨ͜͠ͱ͋ͬͨͷͰ͕͢ɺݸ ਓతʹλεΫϥϯφʔͱͯ͠ͳΒMakefileͷํ͕ॻ͖͢ ͍ 19
ڥߏஙํ๏ • MakefileΛ༻ҙ • γΣϧεΫϦϓτΛ༻ҙ͍ͯͨ͜͠ͱ͋ͬͨͷͰ͕͢ɺݸ ਓతʹλεΫϥϯφʔͱͯ͠ͳΒMakefileͷํ͕ॻ͖͢ ͍ • zshͳΒmakeίϚϯυͷิޮ͘ 19
Makefile setup-tools: brew bundle mint bootstrap bundle install QRίʔυ: github.com/yusuga/xcode-setup/App/Makefile
20
Makefile setup-carthage: mint run carthage bootstrap QRίʔυ: github.com/yusuga/xcode-setup/App/Makefile 21
Makefile setup-cocoapods: bundle exec pod install QRίʔυ: github.com/yusuga/xcode-setup/App/Makefile 22
ڥߏஙํ๏ ❯ make • ҎԼ͕࣮ߦ͞ΕΔ 1. brew bundle 2. mint
bootstrap 3. bundle install 4. mint run carthage bootstrap 5. mint run swiftgen 6. mint run xcodegen 7. bundle exec pod install 8. open App.xcworkspace QRίʔυ: github.com/yusuga/xcode-setup/App/Makefile 23
ڥߏஙํ๏ 24
ڥߏஙํ๏ • Swiftͷπʔϧ → Mintfile 24
ڥߏஙํ๏ • Swiftͷπʔϧ → Mintfile • gemͷπʔϧ → Gemfile 24
ڥߏஙํ๏ • Swiftͷπʔϧ → Mintfile • gemͷπʔϧ → Gemfile •
Carthage → Cartfile 24
ڥߏஙํ๏ • Swiftͷπʔϧ → Mintfile • gemͷπʔϧ → Gemfile •
Carthage → Cartfile • CocoaPods → Podfile 24
ࠓޙղܾ͍ͨ͠՝ 25
ࠓޙղܾ͍ͨ͠՝ • HomebrewɺMintɺbundlerϩʔΧϧڥ͔ΒΓ͍ͨ͠ 25
ࠓޙղܾ͍ͨ͠՝ • HomebrewɺMintɺbundlerϩʔΧϧڥ͔ΒΓ͍ͨ͠ • rbenv͋Δ͚Ͳπϥ͍ 25
ࠓޙղܾ͍ͨ͠՝ • HomebrewɺMintɺbundlerϩʔΧϧڥ͔ΒΓ͍ͨ͠ • rbenv͋Δ͚Ͳπϥ͍ • DockerͰղܾ͍ͨ͠ 25
ࠓޙղܾ͍ͨ͠՝ • HomebrewɺMintɺbundlerϩʔΧϧڥ͔ΒΓ͍ͨ͠ • rbenv͋Δ͚Ͳπϥ͍ • DockerͰղܾ͍ͨ͠ • ڥߏஙͷߴԽ 25
͝੩ௌ͋Γ͕ͱ͏ ͍͟͝·ͨ͠ʂ QRίʔυ: Zenn.dev ϩʔΧϧڥΛՄೳͳݶΓԚછ͠ͳ͍Xcodeͷ։ൃڥߏங 26