Fastfile 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. desc 'ManagerLib 使用这个航道 可以快速的对自己的私有库,进行升级维护'
  2. lane :ManagerLib do |options|
  3. tagName = options[:tag]
  4. targetName = options[:target]
  5. #具体航道上面执行哪些行为
  6. # 1. pod install
  7. cocoapods(
  8. clean: true,
  9. podfile: "./Example/Podfile"
  10. )
  11. # 2. git add .
  12. git_add(path: ".")
  13. # git commit
  14. git_commit(path: ".", message: "添加ijkplayer 解决iOS16 无法播放.m3u8资源")
  15. # git push origin master
  16. push_to_git_remote
  17. # 验证tag是否存在 ,如果存在,应该删除本地标签和远程标签
  18. #if 判断标签是否存在
  19. #执行删除本地/远程标签
  20. #end
  21. if git_tag_exists(tag: tagName)
  22. UI.message("发现tag:#{tagName}已经存在,即将执行删除动作🚀")
  23. remove_tag(tag:tagName)
  24. end
  25. # 3. git tag 标签名称
  26. add_git_tag(
  27. tag: tagName
  28. )
  29. # git push --tags
  30. push_git_tags
  31. # 4. pod spec lint
  32. # pod lib lint --sources='http://60.205.190.38:9000/iOS/MKRPodSpecs.git,https://github.com/CocoaPods/Specs.git' --use-libraries --allow-warnings
  33. pod_lib_lint(allow_warnings: true)
  34. # pod repo push XXX xxx.podspec
  35. pod_push(path: "#{targetName}.podspec", repo: "MKRPodSpecs", allow_warnings: true)
  36. end