美文网首页
iOS cocoapods 创建私有库过程

iOS cocoapods 创建私有库过程

作者: Q14 | 来源:发表于2019-11-28 12:00 被阅读0次

前言因为 我们已经有 pod repo 所以就省略pod repo过程

1. pod lib create GMRouter

屏幕快照 2019-11-28 下午1.15.38.png

2. 修改 GMRouter.podspec

  s.homepage         = 'http://git.*****.com/****/GMRouter.git'
  # s.screenshots     = 'www.example.com/screenshots_1', 'www.example.com/screenshots_2'
  s.license          = { :type => 'MIT', :file => 'LICENSE' }
  s.author           = { 'jz' => '***@***i.com' }
  s.source           = { :git => 'git@git.*****.com:****/GMRouter.git', :tag => s.version.to_s }

3. 添加图片 或者plist

修改 podspec
然后新建文件到 Assets 目录下

  s.resource_bundles = {
    'GMRouter' => ['GMRouter/Assets/*']
  }
屏幕快照 2019-12-10 上午11.11.29.png

4. 在gitlab上创建项目并推到gitlab *****上

git push --set-upstream git@git.*****.com:*****/$(git rev-parse --show-toplevel | xargs basename).git $(git rev-parse --abbrev-ref HEAD)

5. pod lib lint 验证通过后

pod lib lint --verbose --no-clean --allow-warnings --sources='[https://github.com/CocoaPods/Specs,git@git.wanmeizhensuo.com:gengmeiios/GMSpecs.git](https://github.com/CocoaPods/Specs,git@git.wanmeizhensuo.com:gengmeiios/GMSpecs.git)' --fail-fast

相关文章

网友评论

      本文标题:iOS cocoapods 创建私有库过程

      本文链接:https://www.haomeiwen.com/subject/zhzvwctx.html