问题描述:

I have a zipped up iOS framework which I am trying to use via CocoaPods in a test application. I have added it in my github under releases. My podspec currently looks like :

Pod::Spec.new do |spec|

spec.name = "TestPod"

spec.version = "0.1"

spec.license = { :type => "MIT", :file => "LICENSE" }

spec.homepage = 'http://www.test.com'

spec.author = "test"

spec.summary = "test."

spec.source = { :http => "https://github.com/username/TestPod/releases/download/0.1/TestPod-0.1.zip"}

spec.vendored_framework = "TestPod-0.1/TestPod.framework"

spec.ios.deployment_target = '8.0'

end

I'm using this directly in my Podfile with -

target 'TestApp' do

pod 'TestPod', :git => 'https://github.com/username/TestPod/'

end

However, on doing a pod install, I found that the Zipped file TestPod-0.1.zip was neither downloaded nor was the framework added to my project. Can someone please advise me as to how I can get the Pod to download my framework?

网友答案:

You must specify a git repo not just some arbitrary directory. So instead of using: https://github.com/username/TestPod/ (a directory), you should pull the URL that you would use to clone the repo (the HTTPS path not SSH). This is probably https://github.com/username/TestPod.git in your case.

On Github this can generally be found on the top of the repo you want to use. If you are still having problems, please specify the actual repo you are trying to use.

网友答案:

Your podfile should point to the repo. So as your podfile (using the test repo you indicated for TTNew) should look like:

 pod 'TTNew', :git => 'https://github.com/aditya-tirodkar/TTNew.git'
网友答案:

well, I have similar requirement and my pod install do not download my .zip file at http source (tried with git as well as to my http deployment server)

It works like champ with "google-cast-idk".

Any clue would be helpful.

相关阅读:
Top