MeetYouDevs / cocoapods-imy-bin

1.05k stars 245 forks source link

私有库是否支持? #63

Closed xubillde closed 3 years ago

xubillde commented 3 years ago

测试demo: 1.使用pod bin auto --all-make 成功 2.使用pod bin local,没有报错,是否正常?

====== cocoapods-imy-bin 0.3.0.11 版本 ======== 

======  dev 环境 ========

======  dev 环境 ========
更新私有源仓库 com-ios_spec_bin_dev
更新私有源仓库 com-ios_spec_source_dev
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_bin_dev fetch
  origin --progress
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_source_dev fetch
  origin --progress
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_source_dev
  rev-parse --abbrev-ref HEAD
  master
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_bin_dev
  rev-parse --abbrev-ref HEAD
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_source_dev reset
  --hard origin/master
  master
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_bin_dev reset
  --hard origin/master
  HEAD is now at 2a13ed0 Initial commit
  HEAD is now at 7d37e5a [Add] YYModel (1.0.4)

[!] ====== cocoapods-imy-bin 0.3.0.11 版本 ======== 

[!] ======  dev 环境 ======== 

[!] ====== archive-white-pod-list = ["Demo", "YYCache"]

[!] ====== ignore_git_list = ["git@gitlab.xxx.com:Github-iOS"]`

项目: 已依赖多个私有仓库,使用pod bin auto --all-make,无法找到私有库

[!] Unable to find a specification for `HTHJBase`

You have either:
 * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
 * mistyped the name or version.
 * not added the source repo that hosts the Podspec to your Podfile.

配置archive-white-pod-list内添加HTHJBase,使用pod bin local,也是上述的报错

二进制服务器已添加docker部署,demo测试上传成功

su350380433 commented 3 years ago

支持的

xubillde commented 3 years ago

不好意思,描述错误 pod bin auto --all-make 的时候报错。 配置archive-white-pod-list内添加HTHJBase,使用pod bin local,没有报错。白名单外的其他组件没有执行。 这样看起来有两个问题: 1.pod bin auto的时候HTHJBase是私有组件库,好像没找到引起的,但是pod search HTHJBase能搜索到这个私有库 2.把私有组件库加到白名单后,pod bin local,其他组件没有生成二进制,也没有报错


{
    "//":"archive-white-pod-list  制作二进制白名单",
    "archive-white-pod-list" : [
        "HTHJBase",
        "HTHJMacro",
        "HTHJNetwork",
        "HGMiddleware",
        "HGRouter",
        "HTHJCheckVersion",
        "HTHJUserInfoManager",
        "HGThird",
        "HTHJLogManager",
        "HTHJBackLine"
    ]
}
Updating Spec Repositories

====== cocoapods-imy-bin 0.3.0.11 版本 ========

======  dev 环境 ========

======  dev 环境 ========
更新私有源仓库 com-ios_spec_bin_dev
更新私有源仓库 com-ios_spec_source_dev
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_source_dev fetch
  origin --progress
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_bin_dev fetch
  origin --progress
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_source_dev
  rev-parse --abbrev-ref HEAD
  master
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_bin_dev
  rev-parse --abbrev-ref HEAD
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_source_dev reset
  --hard origin/master
  master
  HEAD is now at 2a13ed0 Initial commit
  $ /usr/bin/git -C /Users/xubill/.cocoapods/repos/com-ios_spec_bin_dev reset
  --hard origin/master
  HEAD is now at 7d37e5a [Add] YYModel (1.0.4)

[!] ====== cocoapods-imy-bin 0.3.0.11 版本 ========

[!] ======  dev 环境 ========

[!] ====== archive-white-pod-list = ["HTHJBase", "HTHJMacro", "HTHJNetwork", "HGMiddleware", "HGRouter", "HTHJCheckVersion", "HTHJUserInfoManager", "HGThird", "HTHJLogManager", "HTHJBackLine"]
xubill@xubilldeMacBook-Pro ChemicalIndustryPark %
xubillde commented 3 years ago

命令行

  sources: ["git@gitlab.asoco.com.cn:xubin/ios_spec_bin_dev.git", "git@gitlab.asoco.com.cn:xubin/ios_spec_source_dev.git", "git@gitlab.asoco.com.cn:xubin/ios_spec_bin_dev.git", "git@gitlab.asoco.com.cn:xubin/ios_spec_source_dev.git", "https://cdn.cocoapods.org"], 

bin源码里只包含了二进制的,不支持本地已有其他组件吧?

def self.options
            [
              ['--all', '更新所有私有源,默认只更新二进制相关私有源']
            ].concat(super)
          end

          def initialize(argv)
            @all = argv.flag?('all')
            @name = argv.shift_argument
            super
          end

          def run
            show_output = !config.silent?
            if @name || @all
              config.sources_manager.update(@name, show_output)
            else
              Parallel.each(valid_sources, in_threads: 4) do |source|
                UI.puts "更新私有源仓库 #{source.to_s}".yellow
                source.update(show_output)
              end
            end
          end
xubillde commented 3 years ago

?