I've created a new repository on Github and want to do my first push. All the commands worked until "git push -u origin master", when the following error is prompted:
ssh: Could not resolve hostname github.com:MaryCooperGD: Name or service not known
fatal: Could not read from remote repository.
I've tried following this solution and all the other answers below but didn't work. I've deleted the credentials on the credential manager but git doesn't ask me for new credentials to enter. I've tried closing and reopening the bash but nothing changed. What can I try?
UPDATE: I was able to push by using git remote set url origin with the right URL. Finally git prompted to insert username and password, I inserted mine and the push went ok. The problem is that the commit I see on the repository is under the name of the previous github account that was on the computer, even though I've deleted the credentials and inserted mine.