Changeset View
Changeset View
Standalone View
Standalone View
src/docs/flavor/recommendations_on_branching.diviner
@title Recommendations on Branching | @title Recommendations on Branching | ||||
@group review | @group review | ||||
Project recommendations on how to organize branches. | Project recommendations on how to organize branches. | ||||
This document discusses organizing branches in your remote/origin for feature | This document discusses organizing branches in your remote/origin for feature | ||||
development and release management, not the use of local branches in Git or | development and release management, not the use of local branches in Git or | ||||
queues or bookmarks in Mercurial. | queues or bookmarks in Mercurial. | ||||
This document is purely advisory. Phabricator works with a variety of branching | This document is purely advisory. Phorge works with a variety of branching | ||||
strategies, and diverging from the recommendations in this document | strategies, and diverging from the recommendations in this document | ||||
will not impact your ability to use it for code review and source management. | will not impact your ability to use it for code review and source management. | ||||
= Overview = | = Overview = | ||||
This document describes a branching strategy used by Facebook and Phabricator to | This document describes a branching strategy used by Facebook and Phorge to | ||||
develop software. It scales well and removes the pain associated with most | develop software. It scales well and removes the pain associated with most | ||||
branching strategies. This strategy is most applicable to web applications, and | branching strategies. This strategy is most applicable to web applications, and | ||||
may be less applicable to other types of software. The basics are: | may be less applicable to other types of software. The basics are: | ||||
- Never put feature branches in the remote/origin/trunk. | - Never put feature branches in the remote/origin/trunk. | ||||
- Control access to new features with runtime configuration, not branching. | - Control access to new features with runtime configuration, not branching. | ||||
The next sections describe these points in more detail, explaining why you | The next sections describe these points in more detail, explaining why you | ||||
▲ Show 20 Lines • Show All 88 Lines • ▼ Show 20 Lines | - Disqus described their similar system in a 2010 blog post here: | ||||
[[http://blog.disqus.com/post/789540337/partial-deployment-with-feature-switches | | [[http://blog.disqus.com/post/789540337/partial-deployment-with-feature-switches | | ||||
Disqus Feature Switches]]. | Disqus Feature Switches]]. | ||||
- Forrst describes their similar system in a 2010 blog post here: | - Forrst describes their similar system in a 2010 blog post here: | ||||
[[http://blog.forrst.com/post/782356699/how-we-deploy-new-features-on-forrst | | [[http://blog.forrst.com/post/782356699/how-we-deploy-new-features-on-forrst | | ||||
Forrst Buckets]]. | Forrst Buckets]]. | ||||
- Martin Fowler discusses these systems in a 2010 blog post here: | - Martin Fowler discusses these systems in a 2010 blog post here: | ||||
[[http://martinfowler.com/bliki/FeatureToggle.html | | [[http://martinfowler.com/bliki/FeatureToggle.html | | ||||
Martin Fowler's FeatureToggle]]. | Martin Fowler's FeatureToggle]]. | ||||
- Phabricator just adds config options but defaults them to off. When | - Phorge just adds config options but defaults them to off. When | ||||
developing, we turn them on locally. Once a feature is ready, we default it | developing, we turn them on locally. Once a feature is ready, we default it | ||||
on. We have a vastly less context to deal with than most projects, however, | on. We have a vastly less context to deal with than most projects, however, | ||||
and sometimes get away with simply not linking new features in the UI until | and sometimes get away with simply not linking new features in the UI until | ||||
they mature (it's open source anyway so there's no value in hiding things). | they mature (it's open source anyway so there's no value in hiding things). | ||||
When building this system there are a few things to avoid, mostly related to not | When building this system there are a few things to avoid, mostly related to not | ||||
letting the complexity of this system grow too wildly: | letting the complexity of this system grow too wildly: | ||||
▲ Show 20 Lines • Show All 59 Lines • Show Last 20 Lines |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0