可可豆荚命令在Catalina os中出错,xcode 11

问题描述 投票:-2回答:2

我已经在Catalina os中下载了最新版本的Xcode,但问题是“ pod install”命令在终端上不起作用

错误:

Traceback (most recent call last):
    5: from /usr/local/bin/pod:23:in `<main>'
    4: from /usr/local/bin/pod:23:in `load'
    3: from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/bin/pod:55:in `<top (required)>'
    2: from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:49:in `run'
    1: from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:130:in `verify_minimum_git_version!'
/Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:118:in `git_version': Failed to extract git version from `git --version` ("xcrun: error: active developer path (\"/Applications/Xcode.app/Contents/Developer\") does not exist\nUse `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools.\nSee `man xcode-select` for more details.\n") (RuntimeError)
ios xcode cocoa-touch
2个回答
0
投票

只需在终端中执行此操作,它将起作用:=

    sudo xcode-select --install

0
投票

您是否安装了命令行工具?

如果没有,那么首先通过在终端中执行此命令来安装它:

 xcode-select --install
© www.soinside.com 2019 - 2024. All rights reserved.