Flutter打包iOS过程中pod访问github失败

问题描述

执行Flutter打包iOS命令出现如下错误:

# flutter build ios
...
 Error output from CocoaPods:
↳
         Cloning into '/var/folders/q8/sd0qtp6d69b30yt6gsh1jrg40000gq/T/d20231116-58127-8g2zje'...
         fatal: unable to access 'https://github.com/ccgus/fmdb.git/': Failure when receiving data from the peer

    [!] Automatically assigning platform `iOS` with version `9.0` on target `Runner` because no platform was specified. Please specify a
    platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.

Error running pod install

问题分析

安装失败的原因是网络问题。

解决方案

  1. 开启代理

  2. 配置代理

% export https_proxy=http://127.0.0.1:7890 
  1. 重新打包,执行成功。

你可能感兴趣的:(Flutter,iOS,flutter,ios,github)