0

Recently I'm learning about Git.But something wrong with me,When I type some command.

$ git push -u origin master
ssh: connect to host gmail.com port 22: Connection timed out
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I don't what happend.I try my best to search something about it but noting useful.Please,I'm confused.

John Lee
  • 1
  • 1

1 Answers1

1

ssh: connect to host gmail.com port 22: Connection timed out

As you can see from error message you try to push to gmail.com.
gmail.com - is not a git repository as we know, so you can't push.

To add remote repository use

git remote add <NAME> <PATH>

or to change URL:

git remote set-url <NAME> <PATH>
Roman Marusyk
  • 23,328
  • 24
  • 73
  • 116