I am trying to install locally an R package that stored is in my BitBucket repository via:
remotes::install_git("ssh://git@bitbucket.org/myrepo/mypackage.git", credentials = git2r::cred_ssh_key(".../.ssh/id_rsa.pub", ".../.ssh/id_rsa"))
The download of the repo starts and the following message is printed in the RStudio console:
Downloading git repo ssh://git@bitbucket.org/myrepo/mypackage.git
Nevertheless, after a while the following error occurs:
Error: Failed to install 'unknown package' from Git:
Error in 'git2r_remote_ls': error authenticating: unable to connect to agent pipe
If I try to install another package from the same repo, I get no error.
Any idea on how to solve this issue?