Detailed steps to upload local projects to gitee

1. Create an empty project named after your own project name on gitee

insert image description here

2. Enter the folder of the project you want to upload, and then right click

insert image description here

3. Initialize the local environment and turn the project into a warehouse that can be managed by git

$ git init

4. Add all files under the project

$ git add .   (注意这里有个点)

5. Use the following command to add the file to the warehouse

$ git commit -m '本次提交的说明'(说明信息为必填项,最好是信息有意义,便于后期理解)

6. Associate the local code base with the remote code base

$ git remote add origin https://gitee.com/qlqaq/projects/仓库名称

7. Forcibly update the code of the remote warehouse to the current branch. ps: If the warehouse is empty, this step can be skipped

$ git pull --rebase origin master

8. Push the local code to the specified remote warehouse

$ git push -u origin master

Guess you like

Origin blog.csdn.net/zch981964/article/details/132212967