Giter Site home page Giter Site logo

总结一下一些操作 about exp-code HOT 4 OPEN

deercoder avatar deercoder commented on June 20, 2024
总结一下一些操作

from exp-code.

Comments (4)

deercoder avatar deercoder commented on June 20, 2024

Github上面合并分支出现冲突时怎么办?此时需要手动拉下来来解决冲突并重新提交,具体如下:

Step 1: From your project repository, bring in the changes and test.

git fetch origin
git checkout -b test origin/test
git merge master

Step 2: Merge the changes and update on GitHub.

git checkout master
git merge --no-ff test
git push origin master

也就是说需要在两个分支上面都完成merge操作,然后commit并push到远程,之后就会自动merge并关闭了,此操作值得学习

from exp-code.

deercoder avatar deercoder commented on June 20, 2024

执行完毕后,注意test和master分支实际上是一样的,但是为什么master分支多几个提交呢?因为产生了merge的commit在master分支上面。

不需要care这些细节,此时test和master分支肯定是一样的,而且切换分支不会再有pull request,因为没有差异也不会有多的提交需要合并到master分支。

from exp-code.

deercoder avatar deercoder commented on June 20, 2024

另外还有一点需要注意:test分支上面的提交在github的首页上面看不到,有点小纠结,可能会觉得是实验性代码所以不计入你的提交吧,但是merge到master后就又有了。优点强迫症想刷commit数目的同学还是早点merge吧,因为我发现以后merge冲突的可能性很高,手动解决也纠结,一般我们自己用还是一个master分支就可以了。

from exp-code.

deercoder avatar deercoder commented on June 20, 2024

另外还有一点,发现太傻了,其实还是可以track的,因为那是一个pull request,在平齐的这个tab里面,可以看到有pull request,里面有历史所有的pull request,你点开就可以看到那个comment了,所以没有问题的,还是很容易进去看到。

不过个人觉得_还是_在issue里面会醒目一些而且容易索引,pull request里面可以简单写,issue里面类似于blog来详细说明一下(记得之前有谁是直接把issue当做博客来用的,也是可以的)

from exp-code.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.