Initial push to github not working (problem with ssh connectivity?)

I'm using RStudio 1.1.463 on Windows 10, R 3.6.1. I've created a new package and am trying to push my initial commit to a newly created github repository for the first time. I have a working ssh key that allows me to push and pull git commits from other packages and projects I'm working on without any trouble (located at C:/Users//.ssh/id_rsa).

I've followed the directions from here, successfully ran "git remote add origin ..." in the shell, and then when I try to run git push -u origin master I get the following error:

Could not create directory '/c/.../testpack/=/.ssh'.
The authenticity of host ' (' can't be established.
RSA key fingerprint is [a bunch of alphanumeric code].
Are you sure you want to continue connecting (yes/no)?

When I type yes, I get:
Failed to add the host to the list of known hosts (/c/.../testpack/=/.ssh/known_hosts).
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I've spent the last two hours scouring help forums looking for someone with the same problem but nothing has helped. Does anyone have any advice?

Weirdly, I managed to push successfully using the terminal rather than the shell in RStudio. So I guess that solves it, but I wonder if anyone might now why this would work in the Terminal but not the Shell...

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.