github: permission denied (publickey)
Posted: Wed Mar 06, 2024 10:00 pm
I've had several reasons for the following error:
2. Remote-URL wasn't pointing to any SSH config entry name.
(eg "github.com" instead of just "github" - as labelled in ~/.ssh/config)
3. SSH key was not assigned to any user who had access to that repository (eg: my own account)
1. SSH config (~/.ssh/config) had no public key set.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.
2. Remote-URL wasn't pointing to any SSH config entry name.
(eg "github.com" instead of just "github" - as labelled in ~/.ssh/config)
3. SSH key was not assigned to any user who had access to that repository (eg: my own account)