Here the story. I had an account on GitLab for my job.
Today i decided to create anotherone with another email address for personal use.
When i found out i cannot use the same ssh key i was using for the other account i generated another one, and added it to my new gitlab account.
~/.ssh looks like that
id_rsa id_rsa_personal id_rsa_personal.pub id_rsa.pub known_hosts
I couldn’t push my code.
Then i realized there is this file
~/.ssh/config which i dont know how to use despite all the docs i read which are not clear for me.
# Work account Host One host Hostname firstname.lastname@example.org:mdipaolo PreferredAuthentications publickey User git IdentityFile ~/.ssh/id_rsa # Personal account Host Another host Hostname email@example.com:marcosdipaolo PreferredAuthentications publickey User git IdentityFile ~/.ssh/id_rsa_personal
I really would like some help here.
The project you were looking for could not be found. fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.