aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-docs/src/pages/branches/index.md
diff options
context:
space:
mode:
authorG. Ann Campbell <ganncamp@gmail.com>2018-04-26 13:26:45 -0400
committerSonarTech <sonartech@sonarsource.com>2018-05-03 20:20:50 +0200
commit0c996218c1a2c2542c3465a7bf1f38ee386132da (patch)
tree29f2cf7bd11746d42477958f25c0832f6abde000 /server/sonar-docs/src/pages/branches/index.md
parent4a31f1ff8f39bdd5189d75f420ab052ec5a75cd6 (diff)
downloadsonarqube-0c996218c1a2c2542c3465a7bf1f38ee386132da.tar.gz
sonarqube-0c996218c1a2c2542c3465a7bf1f38ee386132da.zip
SONAR-10612 Added content
Diffstat (limited to 'server/sonar-docs/src/pages/branches/index.md')
-rw-r--r--server/sonar-docs/src/pages/branches/index.md71
1 files changed, 71 insertions, 0 deletions
diff --git a/server/sonar-docs/src/pages/branches/index.md b/server/sonar-docs/src/pages/branches/index.md
new file mode 100644
index 00000000000..0130365285c
--- /dev/null
+++ b/server/sonar-docs/src/pages/branches/index.md
@@ -0,0 +1,71 @@
+---
+title: Branches
+---
+
+_Branch analysis is available as part of [Developer Edition](https://redirect.sonarsource.com/editions/developer.html)_
+
+Branch analysis allows you to
+
+* analyze long-lived branches
+* analyze short-lived branches
+* notify external systems when the status of a short-lived branch is impacted
+
+## Branch Types
+
+### Short-lived
+
+Short-Lived
+This corresponds to Pull/Merge Requests or Feature Branches. This kind of branch:
+
+* will disappear quickly
+* will be merged rapidly to prevent integration issues
+* is developed for a given version, so the version does not change,
+ and there is no Leak Period concept as such; it's all leak period
+ tracks all the new issues related to the code that changed on it.
+
+![conceptual illustration of short-lived branches.](images/short-lived-branch-concept.png)
+
+For more, see [Short-lived Branches](short-lived-branches)
+
+### Long-lived
+
+This corresponds to "Maintenance" Branches that will house several release versions.
+This kind of branch will:
+
+* last for a long time
+* inevitably diverge more and more from the other branches
+* house several release versions, each of which must pass the quality gate
+ to go to production not be expected to be merged into another branch
+
+![conceptual illustration of long-lived branches.](images/long-lived-branch-concept.png)
+
+For more, see [Long-lived Branches](long-lived-branches)
+
+### Master / Main Branch
+
+This is the default, and typically corresponds to what's being developed for
+your next release. This is usually known within a development team as
+"master" or "head", and is what is analyzed when no specific branch parameters
+are provided. It is labeled "Main Branch" and defaults to the name "master",
+but can be renamed from within the interface. When you are not using Developer Edition, this is the only branch you see.
+
+## Analysis
+
+A branch is created when the `sonar.branch.name` parameter is passed during analysis.
+
+| Parameter Name | Description |
+| --------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
+| `sonar.branch.name` | Name of the branch (visible in the UI) |
+| `sonar.branch.target` | Name of the branch where you intend to merge your short-lived branch at the end of its life. If left blank, this defaults to the master branch. It can also be used while initializing a long-lived branch to sync the issues from a branch other than the Main Branch. |
+
+### Git History
+
+By default, TravisCI only fetches the last 50 git commits. You must use `git fetch --unshallow` to get the full history. If you don't, new issues may not be assigned to the correct developer.
+
+### Configuring the Branch type
+
+A regular expression is used to determine whether a branch is treated as long-lived or short-lived. By default, branches that have names starting with either "branch" or "release" will be treated as long-lived.
+
+This can be updated globally in **Configuration > General > Detection** of long-lived branches or at project's level in the **Admininstration > Branches**.
+
+Once a branch type has been set, it cannot be changed. Explicitly, you cannot transform a long-lived to short-lived branch, or vice-versa.