位桶工作流程

Bitbucket workflow

我想知道 git 和带分支的 bitbucket 的流程。

假设我在 Bitbucket 上创建了以下分支:

硕士 特征1 功能 2

在 phpstorm 上,我克隆了存储库,现在我检查了分支 Feature1

我做了我的改变并承诺。

接下来我该做什么?

我应该

1.checkout大师

  1. 拉取 master

  2. 的更改
  3. 然后合并到Feature1分支

在我将我的 Feature1 分支更改推送到远程 Feature1 然后创建拉取请求之前?

我尝试查看 bitbucket 文档,但找不到。

我担心的是在将我的 feature1 推送到远程 feature1 之前如何与主分支同步以便我可以执行拉取请求?

有许多工作流程变体,但我建议采用以下典型流程:

# update your local master
git checkout master
git pull

# integrate recent changes from master into your branch
git checkout Feature1
git rebase master

# at this point, if any, resolve all conflicts normally and proceed

# then you can send your branch to the remote
git push origin HEAD

...最后,在 Bitbucket 上创建一个拉取请求 Feature1 > master