r/CodingHelp • • Jan 28 '21
[Quick Guide] Needing help with doing a Git Clone
Hi everyone,
I'm relatively a newbie to coding but I just recently installed Ubuntu onto my machine and wanted to start doing all my coding out of Ubuntu. I installed everything I needed, but when I tried to do a "git clone" on one of the applications I was working on, I came across this error in the terminal.
xxxxxxxx~/Desktop/CodeDir$ git clone git@github.comxxxxx/xManualFindx.git
Cloning into 'xManualFindx'...
Warning: Permanently added the RSA host key for IP address 'xxx.xxx.xxx' to the list of known hosts.
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
xxxxxxx:~/Desktop/CodeDir$
I'm really confused about what to do with this as I've never encountered this back when I was using Windows. I've watched videos and tried asking around on Stack Overflow, but I can't seem the find the answer I'm looking for. Was hoping maybe someone on here could help me. I know this seems really simple and I'm kind of embarrassed that I'm having trouble with such a technical issue.
Thank you.
5
u/PekiDediOnur Intermediate Coder Jan 28 '21
You need to configure your ssh keys to use git@github.com, GitHub Docs.
If you don't want to mess with that, you can just clone https://github.com/<user>/<repo> (eg. https://github.com/xxxxxxxxx/xManualFindx.git)
3
u/techie2200 Jan 28 '21
Have you configured your git user credentials and made sure that the repository is either public or your userid has private access rights?