每当我打开RStudio时,如何禁用弹出的"git requirements"?

LC-*_*ist 6 git version-control xcode popup rstudio

几个月前,我正在探索RStudio设置,并启用了RStudio项目的版本控制界面,但由于我没有Xcode或命令行开发工具,每次打开RStudio时都会弹出一个弹出窗口," 'git'命令需要命令行开发工具,"并希望我安装它们.

弹出窗口截图

我知道Xcode占用了大量的存储空间,我的MacBook空间非常有限,所以我不想安装它们.现在已经好几个月了,我的忍耐力也越来越差.我真的希望这个弹出窗口停止.如何阻止此消息出现?

我尝试过的事情:在Git/SVN设置中禁用版本控制并重新启动,关闭所有项目和脚本并重新启动,重新安装/更新RStudio和R.

cro*_*cro 2

这似乎与对 的调用有关/usr/bin/git,这是 Mac 上默认安装的 git 二进制文件(或者至少在我的 - MacBook Air(13 英寸,2015 年初),升级到 Sierra)上。执行/usr/bin/git(或/usr/bin/svn)会显示 xcode 消息和对话框。

xcode-select: note: no developer tools were found at '/Applications/Xcode.app', requesting install. Choose an option in the dialog to download the command line developer tools.
Run Code Online (Sandbox Code Playgroud)

我使用 Homebrew 安装了 git,所以现在是它了/usr/local/bin/git

我的解决方案是移动/usr/bin/git/usr/bin/git.bak(以防万一),并git使用 .符号链接到我的实际二进制文件sudo ln /usr/local/bin/git /usr/bin/git