git从本地仓库上传到GitHub
选中项目右键调出Git Bash here,
1、先检查和远程仓库的链接状态ssh -T git@github.com
Hi SledgeWang! You’ve successfully authenticated, but GitHub does not provide shell access.
2、设置用户名和邮箱
git config —global user.name “56******19@qq.com”
git config —global user.email “56******19@qq.com”
3、添加远程地址
git remote add origin https://github.com/SledgeWang/heque.git
但是报错了:fatal: not a git repository (or any of the parent directories): .git ===>初始化 git init
执行刚才的远程地址添加
4、添加和提交
git add .
git commit -m “2018/08/24 11:57:00”
5、push
git push,会弹出GitHub用户登录
还没有评论,来说两句吧...