How to use Git and SourceTree to manage projects on Coding.net - "Second Use"

Author: San Nian

Note: If you have not installed the two software Git and SourceTree on your computer, I suggest you first browse my blog post:
How to Use Git and SourceTree to Manage Projects on Coding.net - "One Installation"


1. First register your codingNet account password: such as: account xxxxx:@xx.com password: mmmmm

write picture description here

2After logging in. Go to the following page and click Create Project

write picture description here

3. Set the project properties as follows (you can also configure it yourself, here is just a simple tutorial), click New Project

write picture description here

4. After creation, you can see the project dynamics as shown below

write picture description here

5. Next, open the SourceTree you installed as follows, create a new one

write picture description here

6. Fill in the information as follows

write picture description here

7. After clicking, jump out of the following interface to create a local warehouse

write picture description here

8. Temporarily store all, click Submit to the local warehouse

write picture description here

9. Set up remote warehouse

write picture description here

10. Find the address of your remote warehouse (on the page on the Coding.net website) and click the copy icon to the right of the address

write picture description here

11. Fill in the information as follows (where the URL path is the address just assigned)

write picture description here

write picture description here

12. You can see that the branch master has been created

write picture description here

13. Now we modify the content of a file
write picture description here

write picture description here

write picture description here

write picture description here

write picture description here

write picture description here

这样你就讲你的项目推送到你的远程仓库里,当然还有其他操作:
这里提供一些名词解释,需要深入的朋友可以继续研究


克隆(clone):从远程仓库URL加载创建一个与远程仓库一样的本地仓库
提交(commit):将暂存文件上传到本地仓库(我们在Finder中对本地仓库做修改后一般都得先提交一次,再推送)
检出(checkout):切换不同分支
添加(add):添加文件到缓存区
移除(remove):移除文件至缓存区
暂存(git stash):保存工作现场
重置(reset):回到最近添加(add)/提交(commit)状态
合并(merge):将多个同名文件合并为一个文件,该文件包含多个同名文件的所有内容,相同内容抵消
抓取(fetch):从远程仓库获取信息并同步至本地仓库
拉取(pull):从远程仓库获取信息并同步至本地仓库,并且自动执行合并(merge)操作,即 ** pull=fetch+merge **
推送(push):将本地仓库同步至远程仓库,一般推送(push)前先拉取(pull)一次,确保一致
分支(branch):创建/修改/删除分枝
标签(tag):给项目增添标签
工作流(Git Flow):团队工作时,每个人创建属于自己的分枝(branch),确定无误后提交到master分枝
终端(terminal):可以输入git命令行

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326708473&siteId=291194637