Slide 1

Slide 1 text

dependency management

Slide 2

Slide 2 text

iOS OS X watchOS tvOS

Slide 3

Slide 3 text

why?

Slide 4

Slide 4 text

lots of problems were solved by smarter people

Slide 5

Slide 5 text

don’t reinvent the wheel

Slide 6

Slide 6 text

unless you plan on learning more about wheels

Slide 7

Slide 7 text

how to choose?

Slide 8

Slide 8 text

forks?

Slide 9

Slide 9 text

watchers?

Slide 10

Slide 10 text

pull requests?

Slide 11

Slide 11 text

open issues?

Slide 12

Slide 12 text

releases?

Slide 13

Slide 13 text

documentation?

Slide 14

Slide 14 text

unit tests?

Slide 15

Slide 15 text

metrics

Slide 16

Slide 16 text

understand everything

Slide 17

Slide 17 text

CocoaPods quality index

Slide 18

Slide 18 text

bus factor !

Slide 19

Slide 19 text

gem install github_bus_factor +-----+-----------------------------------------------------------+ | afnetworking/afnetworking | +-----+-----------------------------------------------------------+ | ! | 7298 forks. | | " | 1684 watchers. | | # | 22999 stars. | | $ | Created over 4 years ago; last push about 10 hours ago. | | % | 1182 PRs: 1167 closed; 15 opened; 98.73% PRs are closed. | | & | Deletions to additions ratio: 74.72% (-136225/182307). | | ' | 34 releases; latest release "3.0.4": about 2 months ago. | | ( | Bus factor: 100.0%. Most likely one core contributor. | +-----+-----------------------------------------------------------+

Slide 20

Slide 20 text

semantic versioning !!!

Slide 21

Slide 21 text

1.2.3

Slide 22

Slide 22 text

how?

Slide 23

Slide 23 text

No content

Slide 24

Slide 24 text

sets up everything for you

Slide 25

Slide 25 text

actively maintained

Slide 26

Slide 26 text

huge userbase

Slide 27

Slide 27 text

Podfile

Slide 28

Slide 28 text

source 'https://github.com/CocoaPods/Specs.git' source 'https://github.com/keslcod/specs.git' platform :ios, '7.0' inhibit_all_warnings! def common_pods pod 'Aspects', git: 'https://github.com/keslcod/Aspects', tag: '1.4.3' pod 'ISO8601DateFormatter', git: 'https://github.com/keslcod/iso-8601-date-formatter', tag: '0.7.1' pod 'Mantle', '~>1.5' pod 'NSDate-Escort', git: 'https://github.com/keslcod/NSDate-Escort', tag: '1.5.3' end target 'Apotheken', exclusive: true do common_pods pod 'ActionSheetPicker-3.0' pod 'DZNEmptyDataSet' pod 'FXReachability', '~> 1.1' pod 'GBDeviceInfo', '~> 3.0' pod 'GoogleAnalytics', '~> 3.0' pod 'GoogleMaps', '~>1.10' pod 'GRMustache', '~> 7.3' pod 'HockeySDK' pod 'LiveFrost' pod 'M13BadgeView', git: 'https://github.com/keslcod/M13BadgeView.git' pod 'MagicalRecord/Core+Logging', git: 'https://github.com/magicalpanda/MagicalRecord.git', commit: 'e1703233f141535263555ca154c559a86c127e23' pod 'MD5Digest' pod 'MDCalendar', git: 'https://github.com/keslcod/MDCalendar.git' pod 'MKMapViewZoom' pod 'MWPhotoBrowser', git: 'https://github.com/keslcod/MWPhotoBrowser.git' pod 'PSTAlertController' pod 'PureLayout' pod 'RHAddressBook', '~>1.1' pod 'SDWebImage', :head pod 'SMCalloutView', '~> 2.1' pod 'SVProgressHUD', :head pod 'SVWebViewController', '~>1.0' pod 'TFBarcodeScanner', '~>1.1' pod 'UIButton+TouchAreaInsets' pod 'XLForm', git: 'https://github.com/keslcod/XLForm.git' end target 'Apotheken Watch App Extension', :exclusive => true do platform :watchos, '2.0' common_pods end target 'Apotheken Watch App', :exclusive => true do platform :watchos, '2.0' common_pods end

Slide 29

Slide 29 text

pod install

Slide 30

Slide 30 text

it just works™

Slide 31

Slide 31 text

unless it doesn’t

Slide 32

Slide 32 text

CocoaPods !

Slide 33

Slide 33 text

Unable to read CocoaPods-version.yml

Slide 34

Slide 34 text

ruby

Slide 35

Slide 35 text

hard to understand if something goes wrong

Slide 36

Slide 36 text

.xcconfig files become difficult to use

Slide 37

Slide 37 text

requires .podspec file

Slide 38

Slide 38 text

breaking .podspec changes

Slide 39

Slide 39 text

Carthage

Slide 40

Slide 40 text

only manages dependencies

Slide 41

Slide 41 text

Cartfile

Slide 42

Slide 42 text

Cartfile github "ReactiveCocoa/ReactiveCocoa" >= 2.3.1 github "jspahrsummers/xcconfigs" github "Mantle/Mantle" ~> 1.0 git "file:///directory/to/project" "branch"

Slide 43

Slide 43 text

Cartfile.private

Slide 44

Slide 44 text

Carthage !

Slide 45

Slide 45 text

you must setup everything

Slide 46

Slide 46 text

bugs in Apple’s toolchain

Slide 47

Slide 47 text

Swift package manager

Slide 48

Slide 48 text

Manager is still in early design and development (…) all details are subject to change and many important features are yet to be

Slide 49

Slide 49 text

demo !

Slide 50

Slide 50 text

tips adjust .gitignore git/svn add Carthage/Checkouts git/svn add Pods git commit -m 'Update Carthage/Pods'

Slide 51

Slide 51 text

links 4 http://blog.codinghorror.com/dont- reinvent-the-wheel-unless-you-plan-on- learning-more-about-wheels/ 4 https://cocoapods.org 4 https://github.com/carthage/carthage 4 https://guides.cocoapods.org/making/ quality-indexes.html 4 https://en.wikipedia.org/wiki/ Bus_factor

Slide 52

Slide 52 text

links 4 https://github.com/zats/ github_bus_factor 4 https://swift.org/package-manager