通过VSCode上传文件夹至github
如果是第一次连接github账户,则需要设置ssh。
1  |  | 
生成SSH Key的秘钥对:参考博客
1  |  | 
首先在GitHub上创建一个Repository,复制url
在一个空文件夹中打开终端,输入
1  |  | 
而后即可用VSCode打开文件夹,使用其功能进行push pull功能了
上传步骤为:commit all ->push
拉取即为pull
commit时需要写一些提交备注。
实际上VSCode还提供其他的一堆命令,不过这几个命令就够用了,出了问题再用其他的
tip:
 1  拉取仓库时修改url
1  |  | 
而后在.git/config文件中改回来,这样拉取的速度可以加快。
vscode设置git文件可见
 2 上传时不能开代理,否则会出现一些问题
 OpenSSL SSL_read: Connection was reset, errno 10054
 实际上我只是因为打开了clash,不是上述的原因,不过可以通过以下命令修改github最大文件限制
 1
git config  --global http.postBuffer 5242880003
 3 GnuTLS recv error (-110): The TLS connection was non-properly terminated
 1
2
3
4
5
6
7
8
9
10
11
12 #方法1
 apt-get install gnutls-bin
git config --global http.sslVerify false
git config --global http.postBuffer 1048576000
#方法2
重置代理,解决
git config --global  --unset https.https://github.com.proxy 
git config --global  --unset http.https://github.com.proxy 
//取消http代理
git config --global --unset http.proxy
//取消https代理 
git config --global --unset https.proxy
 方法3
 Stack Overflow中里说需要用源码重新编译
 方法4(我自己的方法):
1  |  | 
不过我之前也成功推送过,不知道具体原因。。。
迁移至gitee..,github访问太多问题
好像用ssh方式推送能避免很多问题,不过已经迁移完了。
git remote add增加远程仓库,也可以直接修改./git/config文件url


Git Clone错误解决:GnuTLS recv error (-110): The TLS connection was non-properly terminated