Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 56 lines (30 sloc) 2.625 kb
80ba176 @alloy Add a README.
alloy authored
1 # A repository of CocoaPods specifications.
2
3 [![Build Status](https://secure.travis-ci.org/CocoaPods/Specs.png?branch=master)](http://travis-ci.org/CocoaPods/Specs)
4
5 This repository contains specifications of open-source Objective-C libraries, which are used by [CocoaPods](https://github.com/CocoaPods/CocoaPods) to manage library dependencies for your Xcode project.
6
7
8 ### Creating specifications
9
10 First of all, you need to install the tools.
11
12 $ [sudo] gem install cocoapods
e3c62a4 @alloy [New Pod] ZipKit: An Objective-C Zip framework for Mac OS X and iOS.
alloy authored
13 $ pod setup
80ba176 @alloy Add a README.
alloy authored
14
0446b47 @alloy Add part about version tags and asking the library author about them to ...
alloy authored
15 CocoaPods uses a versioning scheme known as [Semantic Versioning](http://semver.org/). See this [example](https://github.com/CocoaPods/Specs/wiki/Cross-dependencies-resolution-example) for more info on why this scheme is used.
16
234db75 @alloy Fix link to ‘please add tags’ issue template.
alloy authored
17 If the library, that you are creating a specification for, does not yet have any tagged versions in its repo, then it’s best to start with the lowest version ‘0.0.1’, which will ensure that once the author does add tagged versions they will be equal or higher than ‘0.0.1’. It is _your_ responsibility to ask the author of the library to tag versions, luckily we have [a template](https://github.com/CocoaPods/Specs/wiki/%22Please-add-semantic-version-tags%22-issue-template) for this.
0446b47 @alloy Add part about version tags and asking the library author about them to ...
alloy authored
18
80ba176 @alloy Add a README.
alloy authored
19 A specification file has to be namespaced by the library’s name and the version for which the specification is meant. For instance, the directory for a library named ‘Bananas’ with version ‘1.2.3’ should be:
20
21 $ mkdir -p Bananas/1.2.3
e3c62a4 @alloy [New Pod] ZipKit: An Objective-C Zip framework for Mac OS X and iOS.
alloy authored
22 $ cd Bananas/1.2.3
80ba176 @alloy Add a README.
alloy authored
23
24 Then you can have the CocoaPods `pod` command create a stub specification:
25
e3c62a4 @alloy [New Pod] ZipKit: An Objective-C Zip framework for Mac OS X and iOS.
alloy authored
26 $ pod spec create Bananas
80ba176 @alloy Add a README.
alloy authored
27
28 Now edit the stub specification following the explanations therein contained. This file is a [Ruby](http://www.ruby-lang.org/) source file.
29
e3c62a4 @alloy [New Pod] ZipKit: An Objective-C Zip framework for Mac OS X and iOS.
alloy authored
30 $ vim Bananas.podspec
80ba176 @alloy Add a README.
alloy authored
31
32 You can verify the specification file with the lint command.
33
e3c62a4 @alloy [New Pod] ZipKit: An Objective-C Zip framework for Mac OS X and iOS.
alloy authored
34 $ pod spec lint Bananas.podspec
80ba176 @alloy Add a README.
alloy authored
35
beda002 @siuying add Hint on how to test the podspec locally
siuying authored
36 Before create a pull request, please verify the specification on a test project locally. Create a Podfile:
637ebd1 @subdigital Mention the rake lint task in the readme
subdigital authored
37
beda002 @siuying add Hint on how to test the podspec locally
siuying authored
38 ```ruby
39 platform :ios
40 dependency 'Bananas', :podspec => 'Bananas.podspec'
41 ```
637ebd1 @subdigital Mention the rake lint task in the readme
subdigital authored
42
beda002 @siuying add Hint on how to test the podspec locally
siuying authored
43 where `:podspec` point to a file.
637ebd1 @subdigital Mention the rake lint task in the readme
subdigital authored
44
80ba176 @alloy Add a README.
alloy authored
45 Once you have created a working specification create a pull request. Once accepted, you will receive push access to this repo. Feel free to push updates, specs for other libraries you use, and participate in other tickets.
46
beda002 @siuying add Hint on how to test the podspec locally
siuying authored
47 You can also verify the entire set by running the rake task.
48
49 $ rake lint
50
51 _(Note: this is run on every commit by [Travis](http://travis-ci.org/#!/CocoaPods/Specs))_
80ba176 @alloy Add a README.
alloy authored
52
53 ### License
54
55 These specifications and CocoaPods are available under the [MIT license](http://www.opensource.org/licenses/mit-license.php).
Something went wrong with that request. Please try again.