gpt4 book ai didi

macos - xcode-select-switch 不起作用 : active developer path does not exist

转载 作者:行者123 更新时间:2023-12-02 08:15:40 24 4
gpt4 key购买 nike

我已经安装了 Xcode 5 开发者预览版 3。之前我安装了开发者预览版 2,现在,有时在我的终端中我会看到错误,例如当我尝试通过选项卡自动完成一些命令时:

error: active developer path ("/Applications/Xcode5-DP2.app/Contents/Developer") does not exist, use xcode-select to change

我尝试通过执行命令来更改此目录:

sudo xcode-select -switch /Applications/Xcode5-DP3.app/Contents/Developer

现在 xcode 具有正确的路径,因为命令

sudo xcode-select -print-path

显示结果:

 /Applications/Xcode5-DP3.app/Contents/Developer    

但我仍然在终端中看到相同的错误,请参阅附件:https://dzwonsemrish7.cloudfront.net/items/120Z1S0b1Q302w3J453U/Screen%20Shot%202013-07-24%20at%2016.34.23.png?v=45e9961b

最佳答案

这发生在我身上一次:xcode-select -print-path 确实坚持相同的值并且没有改变。它似乎总是等于 DEVELOPER_DIR 环境变量。根据 xcode-select 的联机帮助页:

When DEVELOPER_DIR is set, its value will be used instead of the value last passed to -switch xcode_path

因此,取消设置 DEVELOPER_DIR 会使 xcode-select -switch 正常工作。

关于macos - xcode-select-switch 不起作用 : active developer path does not exist,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17834272/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com