【问题标题】:pod spec lint failspod spec lint 失败
【发布时间】:2015-03-03 19:29:07
【问题描述】:

我制作了一个 Swift 框架,我想为它制作一个 CocoaPods。
我已按照所有说明进行操作:

  • 创建podspec文件,添加版本标签,推送到github 当我运行 pod lib lint 时它通过了,但是当我运行 pod spec lint 时它失败了。

这是我的 podspec 文件

Pod::Spec.new do |s|

  s.name         = "Seru"
  s.version      = "0.0.3"
  s.summary      = "Seru is Simple Core Data stack"
  s.description  = <<-DESC
                   Seru is Swift framework for working wit Core Data. It setup your core data stack and 
                   gives you nica actions to work with it
                   DESC

  s.homepage     = "https://github.com/kostiakoval/Seru"
  s.license      = { :type => "MIT", :file => "LICENSE" }
  s.author             = { "Kostiantyn Koval" => "konstantin.koval1@gmail.com" }
  s.social_media_url   = "http://twitter.com/kostiakoval"

  s.platform     = :ios, "8.0"
  s.source       = { :git => "https://github.com/kostiakoval/Seru.git", :tag => s.version }

  s.source_files  = "Seru/Source", "Seru/Source/**/*.{swift}"
  s.requires_arc = true
  s.ios.vendored_frameworks = 'Carthage/Build/iOS/Sweet.framework'

end

它有外部框架依赖。我猜这是一个问题。 当我做 pod speck lint 时,它说我找不到那个外部框架

【问题讨论】:

    标签: ios swift cocoapods


    【解决方案1】:

    问题在于 CocoaPods 不包含 vendored_frameworks 文件夹。
    解决方法是使用preserve_paths 指定此文件夹应包含到 CocoaPod 中。

    s.preserve_paths = 'Carthage/Build/iOS/Sweet.framework'

    【讨论】:

      猜你喜欢
      • 2019-10-02
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-03-05
      • 2019-03-18
      • 1970-01-01
      • 2015-11-21
      • 1970-01-01
      相关资源
      最近更新 更多