One of my friend added me on his Project on Github, as a collaborator. I am able to see the repo, but when I try to clone with this :
git clone https:/github.com/FriendsUserName/FriendsRepo.git
Gets errors:
remote: Repository not found.
fatal: repository https:/github.com/FriendsUserName/FriendsRepo.git not found
I have setup multiple Github account successfully, from this article - Github for work and play (multiple accounts)
Has anybody got this problem before?
I also tried to fork the repo and then clone. But still getting same error with clone.
You can clone a private repository from your account and you can also clone a private repository from organization if you're its owner or member. *pat is PAT(Personal Access Token).
If you see this error when cloning a repository, it means that the repository does not exist, you do not have permission to access it, or your GitHub Enterprise Server instance is in private mode.
Just run the git remote update command which updates the local repo with the remote repo and its credentials. If this command is executed without any issues then your issue will be resolved.
A little late to the party, but I got myself in the exact same situation as the asker, so maybe the way I managed to do it will help someone.
The tutorial referred in the question involves creating aliases for the different Github account, e.g. work.github.com
for your work account and me.github.com
for your personal one.
So, in this case, the way you should clone your repo should be (assuming it's for your personal account) :
git clone https:/me.github.com/FriendsUserName/FriendsRepo.git
However, even that didn't work for me.
What did work was using the alias together with the ssh url for cloning, i.e.
git clone [email protected]/FriendsUserName/FriendsRepo.git
If this still doesn't work, try to see that you are indeed connecting with the correct account :
ssh -T [email protected]
The response to that should be :
Hi <username for personal account here>! You've successfully authenticated, but GitHub does not provide shell access.
Good luck!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With