How to close off a Git Branch?

前端 未结 3 460
予麋鹿
予麋鹿 2021-01-29 17:55

I\'m starting out using Git + GitHub.

In our distributed team, each member is creating their own branch for each issue/requirement they are allocated.

3条回答
  •  轮回少年
    2021-01-29 18:14

    We request that the developer asking for the pull request state that they would like the branch deleted. Most of the time this is the case. There are times when a branch is needed (e.g. copying the changes to another release branch).

    My fingers have memorized our process:

    git checkout 
    git pull
    git checkout 
    git pull
    git merge --no-ff 
    git push
    git tag -a branch- -m "Merge  into "
    git push --tags
    git branch -d 
    git push origin :
    

    A branch is for work. A tag marks a place in time. By tagging each branch merge we can resurrect a branch if that is needed. The branch tags have been used several times to review changes.

提交回复
热议问题