问题一:
fatal: unable to access 'https://github.com/huihuangliu/robomaster.git/': Failed to connect to github.com port 443: Timed out
在网上查找了一下,发现出现该问题的原因是不能访问github.com.
于是cmd上ping github.com, ping不通
解决办法如下:
打开 hosts文件,地址:C:\Windows\System32\drivers\etc
然后在hosts文件中添加:
192.30.253.112 github.com
151.101.88.249 github.global.ssl.fastly.net
参考自: https://blog.csdn.net/sdta25196/article/details/80203152
问题二:git报错: remote origin already exist
解决办法:
删除后再添加就可以了
如何删除: git remote rm origin
问题三:
git上传本地文件遇到error:src refspec master does not match any
一般是在push的时候报错,解决方法如下:
将文件夹下隐藏的.git 通过 git init 命令覆盖. 相当于初始化文件夹为git文件夹(此操作会将你的git文件夹之前的git记录初始化)