前言
记录一下自己第一次使用git上传项目到Gitee防止以后忘记(Windows)
一、安装git
这里我用的是Windows版的,下载安装包后直接安装就可以了,这里有个诀窍一定要注意:安装的时候闭着眼睛下一步。
二、上传流程
1.在需要上传的文件夹目录右击选择Git Bash Here

2.输入命令(每输入一条回车)
git config --global user.name "你Gitee的用户名"
git config --global user.email "你Gitee绑定的邮箱"
git init
注意这里(.)点的前面有一个空格
git add .
git commit -m "提交"
3.效果

4.Gitee上创建一个仓库并复制链接

5.登录Gitee并push项目到仓库
git push -u 上一步复制的链接 master
6.效果

7.上传成功

三、可能出现的问题
(1)remote: error: GE007: Your push would publish a private email address.
info: detecting host provider for 'https://gitee.com/'...
info: detecting host provider for 'https://gitee.com/'...
Enumerating objects: 50, done.
Counting objects: 100% (50/50), done.
Delta compression using up to 6 threads
Compressing objects: 100% (46/46), done.
Writing objects: 100% (50/50), 23.08 MiB | 814.00 KiB/s, done.
Total 50 (delta 6), reused 0 (delta 0), pack-reused 0
remote: Powered by GITEE.COM [GNK-6.1]
remote: error: GE007: Your push would publish a private email address.
remote: You can make your email public or disable this protection by visiting:
remote: https://gitee.com/profile/emails
remote: error: hook declined to update refs/heads/master
To https://gitee.com/molihuan/bilibili-ffmpeg.git
! [remote rejected] master -> master (hook declined)
error: failed to push some refs to 'https://gitee.com/molihuan/bilibili-ffmpeg.git

(1)解决方案:把下面的勾勾去掉

|