我是一个开始使用git的初学者。我已经在github上创建了我的账号,也创建了一个新的代码库。但是我无法使用终端推送或更新github上的更改。我正在运行以下命令:
mkdir ~/TestApplication
cd ~/TestApplication
git init
touch README
git add README
git commit -m 'first commit'
git remote add origin https://github.com/vinayptl/TestApplication.git
git push origin master
当我执行最后一个命令
git push origin master
时,它会冻结一段时间并出现以下错误:error: Failed connect to github.com:443; Connection timed out while accessing
https://github.com/vinayptl/TestingApplication.git/info/refs
fatal: HTTP request failed
我在Linux平台上工作。可能是什么问题呢?我看了一些SO的答案,但无法解决这个问题。
git remote set-url origin git@github.com:username/TestApplication.git
。 - Fred Foo