我正在尝试使用 devtools::release()
将包发布到 CRAN。每当我到达运行 Git 检查...
的步骤时,我都会收到错误。
── Running Git checks for fitzRoy ───────────────────────────────────────────────────────────────────────
Current branch: master
Checking uncommitted files... OK
Checking synchronisation with remote branch...
ERROR: Error in 'git2r_remote_fetch': unsupported URL protocol
我使用的是 Mac。我一直很好地使用 Git 来处理包,并且没有出现任何戏剧性的提交、推送和拉取。
我尝试过更新 devtools、git2r 并安装最新版本的 Git,但没有成功。
有什么建议吗?
最佳答案
更新 - 找到答案 here .
基本上 - 您需要安装libssh2
。在 Mac 上,我按照说明 here 进行操作。 .
然后我必须通过运行以下命令重新安装 R 的 git2r
包
install.packages("git2r", type = "source")
执行此操作并重新启动 R 后,错误消失了。
关于r - 运行 devtools::release() 准备在 R 中发布包时 git 检查时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58741498/