Skip to content

Commit

Permalink
docs(contributors): clarify branching model (#23)
Browse files Browse the repository at this point in the history
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
  • Loading branch information
uniqueg and sourcery-ai[bot] authored Jul 25, 2024
1 parent 97239d3 commit 2e334b4
Showing 1 changed file with 20 additions and 10 deletions.
30 changes: 20 additions & 10 deletions docs/guides/guide-contributor/general-guidelines.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,25 +61,35 @@ visualizes this process.

[![GitHub Flow](../../images/github_flow.svg)][github-flow]

1. [Create a "feature branch"][git-branch] from the default branch; use the
1. [Create a "feature branch"][git-branch] from the development branch; use the
`feature/my-feature` naming pattern to name your feature branch, e.g.,
`feature/update-docs`; make sure the default [branch
`feature/update-docs`; make sure the development [branch
is up to date][git-pull] before creating the feature branch!
2. [Commit code changes][git-commit] to address the issue you are working on
3. [Push the feature branch][git-push] to the remote and [create a pull
request][github-pr] in GitHub
request][github-pr] against the development branch in GitHub
4. Address any comments added during code review by pushing additional commits
(there may be multiple rounds of reviews)
5. Once all issues are resolved, code owners will merge the feature branch into
the default branch using the ["squash merging"][github-merge-squash] method
the development branch using the ["squash merging"][github-merge-squash]
method

!!! note "Development branch"

Typically, `dev` is the name of the development branch in our projects.
In a few cases (e.g., _this_ repository), there is no development branch
and changes are merged immediately into the main branch, typically called
`main`.

!!! note "Default branch"

Typically, `dev` is the default branch for all projects in pre-release
state, i.e., those with version numbers below `v1.0.0`. Upon release,
`main` becomes the default branch, and [semantic versioning][sem-ver] is
strictly adhered by. In some cases, there may not be a `dev` branch and
`main` is used as the default branch straight away.
For projects in pre-release state, i.e., those with version numbers below
`v1.0.0`, the development branch is typically the default branch (meaning
that the correct target branch for your PRs is set automatically).

With the first major release, the default branch is set to the main
branch instead. In that case, make sure to manually select the development
branch as the target branch for your PRs.

??? note "Substantial changes"

Expand Down Expand Up @@ -190,4 +200,4 @@ The [pull request][pull_request] template will be successively added to all
repositories. Until that is the case, you can already make use of it by
self-reviewing your pull requests according to the checklist and descriptions.

[pull_request]: PULL_REQUEST_TEMPLATE.md
[pull_request]: PULL_REQUEST_TEMPLATE.md

0 comments on commit 2e334b4

Please sign in to comment.