pod 'sdwebimage/webp' 下载libwebp 超时
[!] Error installing libwebp[!] /usr/bin/git clone https://chromium.googlesource.com/webm/libwebp /var/folders/p6/t42f8nmd7332018zm9m2s3d80000gn/T/d20180415-42656-1hjxh43 --template= --single-branch --depth 1 --branch v0.6.0Cloning into '/var/folders/p6/t42f8nmd7332018zm9m2s3d80000gn/T/d20180415-42656-1hjxh43'...fatal: unable to access 'https://chromium.googlesource.com/webm/libwebp/': Failed to connect to chromium.googlesource.com port 443: Operation timed out
修改pod repo中libwebp的git source 地址,再执行pod install 解决, 但是我们需要有一个有效的libwebp的git仓库,在github上找到了一个
https://github.com/webmproject/libwebp.git
,可以看到 mirrored from https://chromium.googlesource.com/webm/libwebp
, 下面是步骤:
- 查看mac中cocoapods 本地库路径:
swaedeMacBook-Pro:alpface swae$ pod repo
swaedeMacBook-Pro:alpface swae$ pod repo/Users/swae/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/cocoapods-1.4.0/lib/cocoapods/executable.rb:89: warning: Insecure world writable dir /opt in PATH, mode 040777 master - Type: git (master) - URL: https://github.com/CocoaPods/Specs.git - Path: /Users/swae/.cocoapods/repos/master
- 在本地库中, 并找到对应的libwebp版本的文件
swaedeMacBook-Pro:alpface swae$ find /Users/swae/.cocoapods/repos/master -iname libwebp/Users/swae/.cocoapods/repos/master/Specs/1/9/2/libwebp
进入libwebp目录,可以看到你的仓库中有哪些对应的版本