Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Issue when creating my first CocoaPod

Tags:

ios

cocoapods

I am trying to create my first pod and is following this tutorial: http://www.sitepoint.com/creating-cocoapods/

But when I do:

pod spec lint GLLingoManager.podspec 

I get following error:

$ pod spec lint GLLingoManager.podspec   -> GLLingoManager (0.1.0)     - ERROR | [OSX] unknown: Encountered an unknown error ([!] /Applications/Xcode.app/Contents/Developer/usr/bin/git clone https://github.com/xeppen/GLLingoManager.git /var/folders/v6/tdz6zc7j10j_k0pc1vy627zm0000gn/T/d20160504-76297-8l71fj --template= --single-branch --depth 1 --branch 0.1.0  Cloning into '/var/folders/v6/tdz6zc7j10j_k0pc1vy627zm0000gn/T/d20160504-76297-8l71fj'... warning: Could not find remote branch 0.1.0 to clone. fatal: Remote branch 0.1.0 not found in upstream origin ) during validation.  Analyzed 1 podspec.  [!] The spec did not pass validation, due to 1 error. 

I dont understand what is wrong. What should I do?

like image 968
Sebastian L Avatar asked May 04 '16 21:05

Sebastian L


People also ask

What is the purpose of Podspec?

The spec in a pod, also known as PodSpec, defines the specifications of many behaviors in a declarative manner. A PodSpec defines the containers, environment variables for the container and other properties such as the scheduler name, security context etc.


Video Answer


2 Answers

Add a 0.1.0 version for your github repo. Image from Github incase the link dies:

How to create a version.

like image 85
Dair Avatar answered Sep 24 '22 08:09

Dair


You have pointed to a branch called 0.1.0 in your podspec, and you simply need to push a branch of that name to github. Many people use tags instead of branches to indicate which commit to use for each pod version, and I suggest that you do this instead of pointing to a branch. Please post the source section of your podspec for more specific details.

like image 29
Peter DeWeese Avatar answered Sep 22 '22 08:09

Peter DeWeese