虽然我相信这是无害的,但是警告会让我很恼火。因此,我使用了一个非常特定的版本的TwilioChatClient和TwilioClient。这两个特定的版本就是Twilio在他们的示例项目中使用的版本。
无论如何,安装/更新吊舱时的警告:
好了!为/Users/XXX/.cocoapods/repos/master/Specs/7/d/e/TwilioChatClient/1.0.9/TwilioChatClient.podspec.json - /Users/XXX/.cocoapods/repos/twilio/TwilioChatClient/1.0.9/TwilioChatClient.podspec找到了
TwilioChatClient (1.0.9)
的多个规范 好了!为/Users/XXX/.cocoapods/repos/master/Specs/7/d/e/TwilioChatClient/1.0.8/TwilioChatClient.podspec.json - /Users/XXX/.cocoapods/repos/twilio/TwilioChatClient/1.0.8/TwilioChatClient.podspec找到了TwilioChatClient (1.0.8)
的多个规范 好了!为/Users/XXX/.cocoapods/repos/master/Specs/7/d/e/TwilioChatClient/1.0.7/TwilioChatClient.podspec.json - /Users/XXX/.cocoapods/repos/twilio/TwilioChatClient/1.0.7/TwilioChatClient.podspec找到了TwilioChatClient (1.0.7)
的多个规范 好了!为/Users/XXX/.cocoapods/repos/master/Specs/7/d/e/TwilioChatClient/1.0.6/TwilioChatClient.podspec.json - /Users/XXX/.cocoapods/repos/twilio/TwilioChatClient/1.0.6/TwilioChatClient.podspec找到了TwilioChatClient (1.0.6)
的多个规范 好了!为/Users/XXX/.cocoapods/repos/master/Specs/7/d/e/TwilioChatClient/1.0.5/TwilioChatClient.podspec.json - /Users/XXX/.cocoapods/repos/twilio/TwilioChatClient/1.0.5/TwilioChatClient.podspec找到了TwilioChatClient (1.0.5)
的多个规范 好了!为/Users/XXX/.cocoapods/repos/master/Specs/7/d/e/TwilioChatClient/1.0.4/TwilioChatClient.podspec.json - /Users/XXX/.cocoapods/repos/twilio/TwilioChatClient/1.0.4/TwilioChatClient.podspec找到了TwilioChatClient (1.0.4)
的多个规范
我的文件:
project 'Proj/Proj.xcodeproj'
source 'https://github.com/CocoaPods/Specs'
source 'https://github.com/twilio/cocoapod-specs'
platform :ios, '10.0'
use_frameworks!
target 'Proj' do
pod 'TwilioClient', '~>1.2' # Twilio Call Framework
pod 'TwilioChatClient', '1.0.4' # Twilio Chat Framework
target 'MobileMedTests' do
inherit! :search_paths
end
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '4.0'
end
end
end
end
target 'ProjUITests' do
end
我认为指定两种源(这两者都是必要的)会导致这些警告。有没有办法把特定的源放在吊舱旁边?
发布于 2018-01-07 09:14:12
事实上,您的问题来自这样一个事实:您已经将twilio添加到了您的荚源中,并使用了以下一行:
source 'https://github.com/twilio/cocoapod-specs'
因此,当您键入pod repo
时,可以获得如下内容:
master
- Type: git (master)
- URL: https://github.com/CocoaPods/Specs.git
- Path: /Users/cyrille/.cocoapods/repos/master
twilio
- Type: git (master)
- URL: https://github.com/twilio/cocoapod-specs
- Path: /Users/cyrille/.cocoapods/repos/twilio
当您执行pod install
时,可可荚可以在主人的cocoapods回购和twilio的库中找到该库的版本。发出警告。
若要删除此警告,请从您的Podfile中删除这一行:
source 'https://github.com/twilio/cocoapod-specs'
在终端中执行以下命令:
pod repo remove twilio
然后:
pod update
您应该在没有警告的情况下获得以下信息:
Analyzing dependencies
Removing TwilioClient
Downloading dependencies
Installing TwilioChatClient 2.2.0 (was 1.0.4)
Installing TwilioSDK (1.2.9)
Generating Pods project
Integrating client project
Sending stats
Pod installation complete! There are 2 dependencies from the Podfile and 2 total pods installed.
发布于 2018-01-16 11:27:04
只是想介绍一下你在这里看到的警告的背景。我们在beta测试(https://github.com/twilio/cocoapod-specs)期间使用一个单独的cocoapods存储库,但在1.x发布后不久就开始发布到全局cocoapods存储库。
我们并没有停止在剩下的1.x版本中发布到我们现有的cocoapod规范存储库,因为对于使用beta源代码行的现有客户来说,这将是一个巨大的变化,如果他们也没有声明全球cocoapods存储库的话,他们希望升级。这就是cocoapods所警告的,同一个带有相同版本的荚是在两个地方定义的。podspecs是相同的,因此在使用此警告所显示的任何SDK版本时,这不会引起问题。
从2.x开始,我们只将聊天发布到全局存储库,这就是警告在1.x系列版本中停止的原因。
发布于 2018-01-07 08:56:48
首先,你需要SDK,我现在在我的项目上安装了吊舱。效果很好。查找此链接
http://cocoapods.org/?q=Twilio
Pod码
project 'Proj/Proj.xcodeproj'
source 'https://github.com/CocoaPods/Specs'
source 'https://github.com/twilio/cocoapod-specs'
platform :ios, '10.0'
use_frameworks!
target 'Proj' do
pod 'TwilioSDK', '1.2.9'
pod 'TwilioChatClient'
target 'MobileMedTests' do
inherit! :search_paths
end
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '4.0'
end
end
end
end
target 'ProjUITests' do
end
https://stackoverflow.com/questions/48109435
复制相似问题