MeetYouDevs / cocoapods-imy-bin

1.05k stars 245 forks source link

fix: multiple dependencies error #92

Closed dabing1022 closed 3 years ago

dabing1022 commented 3 years ago

Podfile

target 'Demo' do
  pod 'Masonry'
end

Podfile_local

plugin 'cocoapods-imy-bin'
use_binaries!

target 'Demo' do

    pod 'Masonry', :path => '~/ZZPods/zz-ios-open/Masonry'

end

pod bin install后执行报错:

[!] There are multiple dependencies with different sources for `Masonry` in `Podfile`:

- Masonry
- Masonry (from `~/ZZPods/zz-ios-open/Masonry`)

image

Podfile中的 pod 'Masonry'得到的target_dependency此时是一个String类型(当后面有版本, :git, :podspec等时为Hash类型), 此时target_dependencies.delete target_dependency无法删除,导致两个库重复报错。