Unable to install cocoa pods

后端 未结 3 1838
一整个雨季
一整个雨季 2021-01-17 15:13

I want to install cocoapods on MacOS to run the pod command. But on doing

sudo gem install cocoa-pods

I get the following:

Bui         


        
3条回答
  •  猫巷女王i
    2021-01-17 15:46

    Here is what I did on my Mojave machine:

    • brew reinstall cocoapods
    • brew link --overwrite cocoapods, override the default pod
    $ brew reinstall cocoapods
    ==> Downloading https://homebrew.bintray.com/bottles/cocoapods-1.9.3.mojave.bottle.tar.gz
    ==> Downloading from https://akamai.bintray.com/07/074e5b53b7a054c132582183dcf47546ffffd028a7beb9fcdc653fe4a43225bcf3?__gda__=exp=1593894546~hmac=8b
    ######################################################################## 100.0%
    ==> Reinstalling cocoapods
    ==> Pouring cocoapods-1.9.3.mojave.bottle.tar.gz
    Error: The `brew link` step did not complete successfully
    The formula built, but is not symlinked into /usr/local
    Could not symlink bin/pod
    Target /usr/local/bin/pod
    already exists. You may want to remove it:
      rm '/usr/local/bin/pod'
    
    To force the link and overwrite all conflicting files:
      brew link --overwrite cocoapods
    
    To list all files that would be deleted:
      brew link --overwrite --dry-run cocoapods
    
    Possible conflicting files are:
    /usr/local/bin/pod
    /usr/local/bin/xcodeproj
    ==> Summary
    

提交回复
热议问题