Pod Lib Lint error while maintaining an old POD library:
error: Unexpected duplicate tasks: 1) Target ‘xxxFramework’ (project ‘Pods’) has copy command from ‘/Users/User/Documents/xxx/xxxFramework/xxxFramework/Info.plist’ to ‘/Users/User/Library/Developer/Xcode/DerivedData/App-ftresxeclhzazmebpojycfhpvtjv/Build/Products/Release-iphonesimulator /xxxFramework/xxxFramework.framework/Info.plist’ 2) Target ‘xxxFramework’ (project ‘Pods’) has copy command from ‘/Users/User/Documents/xxx/xxxFramework/xxxFramework/Info.plist’ to ‘/Users/User/Library/Developer/Xcode/DerivedData/App-ftresxeclhzazmebpojycfhpvtjv/Build/Products/Release-iphonesimulator /xxxFramework/xxxFramework.framework/Info.plist’ 3) Target ‘xxxFramework’ (project ‘Pods’) has copy command from ‘/Users/User/Documents/xxx/xxxFramework/xxxFramework/Info.plist’ to ‘/Users/User/Library/Developer/Xcode/DerivedData/App-ftresxeclhzazmebpojycfhpvtjv/Build/Products/Release-iphonesimulator /xxxFramework/xxxFramework.framework/Info.plist’
When searching for a problem, most of the answers are two:
- Duplicate files are added to the Copy Bundle Resource
- Change build System to Legacy
However, in my Pod project, the plist file is not found in the Copy Bundle Resource.
When you manually change the build system of the POD project to Legacy, it is found that when you relint, it does not take effect and will still use pod Note: Using new Build System
So I searched for Pod Note: Use new build system to create a new build system for cocoapod. Use this to create a new build system for cocoapod.
Because of cocoapod, you may have problems compiling some files, such as info.plist, which you see here. Just remove the compilation item:
s.exclude_files = “xxxFramework/xxxFramework/*.plist”