`devtools::install_git()` 具有存储的 git 凭据

`devtools::install_git()` with stored git credentials

当前使用 install_git() 从受 Azure Active Directory 保护的存储库安装会导致错误:

> devtools::install_git("https://myteam.visualstudio.com/MyProject/_git/MyAwesomeRPackage")
Downloading git repo https://myteam.visualstudio.com/MyProject/_git/MyAwesomeRPackage
Installation failed: Error in 'git2r_clone': Unable to authenticate with supplied credentials

即使 AAD 凭据存储在 git 凭据管理器中。例如,从命令行调用它就可以正常工作:

git clone https://myteam.visualstudio.com/MyProject/_git/MyAwesomeRPackage

有什么方法可以让 R 使用来自 git 凭据管理器的凭据进行此安装?

尝试 git 参数,例如 git = "external"