Just follow the steps
git init #初始化仓库(ps:你只需要简单地运行 git init 就可以将一个目录转变成一个 Git 仓库,这样你就可以开始对它进行版本管理了。)
git checkout -b 分支名 #建一个属于自己的分支提交代码方便管理(这句话的意思就是 创建分支并且切换到该分支下)
-----如果不需要的话,也可以不用创建分支-----------
git clone 仓库地址 #拷贝一份远程仓库,也就是下载一个项目。
git clone -b 分支名 仓库地址 #将远程上指定分支的代码克隆到本地
git status #查看仓库当前的状态,显示有变更的文件。
git add . #添加文件到暂存区
git commit -m '备注信息' #将暂存区内容添加到仓库中
git push #上传远程代码并合并
The diagram is as follows:
1. Create the mtl-text-recognition-master folder locally
2. Initialize the warehouse in the mtl-text-recognition-master directory
3. Create a feature/AI-1700 code branch and switch to this branch
4. Clone the code of the designated branch on the remote to the local
5. Copy the file mtl-text-recognition-master to be uploaded to (the file hwrec-chinese copied from the line), as shown in the figure below:
6. Enter the hwrec-chinese directory Next, execute the commands in turn
#########################over#############################