Android svn : xcrun: error: active developer path("")does not exist,use xcode-select to change

在Mac环境下使用Android Studio从SVN下载代码时遇到错误:xcrun: error: active developer path "" does not exist。解决方法包括参照指定博客进行操作,但在执行命令时可能需要管理员权限,通过`su`或`sudo`来执行。

  mac 上的AndroidStudio环境,从SVN down代码的时候,出现了这个错

  解决方案是:   https://www.cnblogs.com/songxing10000/p/4805881.html 。但是照着打完命令后报如下错误,意思是必须得获取管理员权限,这时候就要用su命令root,和sudo执行单条命令:

xingjunchaodeMacBook-Air:~ xingjunchao$ xcode-select -switch /Applications/Xcode.app/Contents/Developer
xcode-select: error: --switch must be run as root (e.g. sudo xcode-select --switch <xcode_folder_path>).

 

  完整命令记录:

xingjunchaodeMacBook-Air:~ xingjunchao$ su 
Password:
su: Sorry
xingjunchaodeMacBook-Air:~ xingjunchao$ xcode-select -switch /Applications/Xcode.app/Contents/Developer
xcode-select: error: --switch must be run as root (e.g. sudo xcode-select --switch <xcode_folder_path>).
xingjunchaodeMacBook-Air:~ xingjunchao$ sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
Password:
xingjunchaodeMacBook-Air:~ xingjunchao$ 

  成功解决: 

 

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值