CocoaPods
CocoaPods manages library dependencies for your Xcode projects.
The dependencies for your projects are specified in a single text file called a Podfile. CocoaPods will resolve dependencies between libraries, fetch the resulting source code, then link it together in an Xcode workspace to build your project.
POD
command line tool to work with pod files
Installation
sudo gem install cocoapods
pod required ruby installation. checko ruby version
ruby -v
to maintain pod local repository use
pod setup
this will create master repo in user-> name-> .cocoapods -> repos...
i think this is lile maven repo. we can maintain repo from local rather than downloading same repo.
this is the main repo path
https://github.com/CocoaPods/CocoaPods
add pod in to project
pod init
to init pod it needs a xcode project. without project no pod init ;)
this will create a pod file.
open pod file using text editor
use xcode interminal use this command
open -a Xcode Podfile
adding required library projects as this
pod 'JLocationKit', '~> 1.0.3'
downloading lib projects
pod install
update missing pods
pod install --repo-update
to run pod project open xcode using App.xcworkspace
do not open using project file
remove pod from a project
$ sudo gem install cocoapods-deintegrate cocoapods-clean
$ pod deintegrate
$ pod clean
$ rm Podfile
No comments:
Post a Comment