Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
CocoaHeads Lyon 17/01/2013 : CocoaPods
1. CocoaPods
“The best way to manage library dependencies in
Objective-C projects.”
CocoaHeads Lyon - janvier 2013
Vincent Tourraine - shazino
2. Pour quoi faire ?
• Gérer les dépendances d’un projet XCode
- Bibliothèques
- Frameworks
- Toutes classes, ressources, etc
3. Comment ça marche ?
1. Écrire un Podfile pour lister les
dépendances
2. Utiliser la commande pod pour générer un
workspace basé sur un projet et les
dépendances du Podfile.
4. Exemple de Podfile
platform :ios
platform :ios
pod
pod 'JSONKit'
'JSONKit'
pod
pod 'AFNetworking', '>= 1.0'
'AFNetworking', '>= 1.0'
pod
pod 'Objection', :head
'Objection', :head
5. Commande pod
• Installation
$
$ (sudo) gem install cocoapods
(sudo) gem install cocoapods
$
$ pod setup
pod setup
6. Commande pod
• Génération du workspace
$ pod install
$ pod install
• Mise à jour du workspace
$ pod update
$ pod update
8. Création du .podspec
• Génération automatique
$ pod spec create [ NAME | https://github.com/USER/REPO ]
$ pod spec create [ NAME | https://github.com/USER/REPO ]
• Test conformité
$ pod spec lint NAME.podspec
$ pod spec lint NAME.podspec
9. Plus d’infos
• Trouver les Pods
http://cocoapods.orghttps://github.com/cocoaPods/Spec
• Documentation
https://github.com/CocoaPods/CocoaPods/wiki
10. Plus d’infos
• Trouver les Pods
http://cocoapods.orghttps://github.com/cocoaPods/Spec
• Documentation
https://github.com/CocoaPods/CocoaPods/wiki