wiki:StartModWorkflow

Version 10 (modified by Beman Dawes, 9 years ago) ( diff )

--

Modular Boost Library Workflow Overview

Workflow is the term used to describe the steps a Boost library developer follows to create and maintain a library.

Git Flow

The workflow model Boost recommends is called Git Flow. It was introduced as a simple blog posting by Vincent Driessen on January 5th, 2010, that went viral and has become a widely used software engineering practice.

This workflow has arguably become so successful because it scales well from very small to very large projects, and that's one of the reasons it is recommended (but not required) for Boost libraries.

  • An unusually simple, single developer library would have only the permanent develop and master branches that are required for all Boost libraries.
  • A more typical library would occasionally add temporary feature branches, either private or public. Feature branch names follow the feature/x model, where x names the specific feature being developed.
  • A larger library, particularly if it has multiple developers, would always have some active public feature branches, and at least occasionally employ release staging branches and hotfix branches. Individual developers would often use private branches.

The Git Flow model diagram is available as a PDF file - print it out and hang it on your wall!

Command line tools

For those who use Git from the command line, git-flow command line tools are available to automate common operations. See git-flow wiki for more information.

Branch names

All Boost libraries are required to have two branches:

  • master is always the library's latest release. It should always be stable.
  • develop is always the main development branch. Whether it is always stable or not is up to the individual library.

These branches are require so that Boost's release management and other scripts can use known branch names.

While Boost libraries are not required to use the following branches, it is strongly encouraged that these naming conventions are followed if the branches are present.

  • feature/descriptive-name for feature branches. For example, feature/add-roman-numeral-math.
  • bugfix/descriptive-name for branches of develop that will be merged back to develop. For example, bugfix/ticket-1234-error-msg-not-clear
  • hotfix/descriptive-name for branches of master that will be merged back to master and also to develop. For example, bugfix/ticket-1234-crash-if-result-negative
  • release.n.n.n for release staging branches. For example, release.1.56.2.

Rationale for choice of Git Flow

  • Git Flow scales well from very small to very large projects. The same overall workflow model serves the whole spectrum of Boost libraries, even though the details differ.
  • Git Flow has become widely known and widely used. Boost doesn't have to pioneer a new workflow.

Aside: Deleting merged branches

The usual culture with Git is to delete feature branches as soon as they are merged to some other branch. This approach is also recommended for Boost developers. After all, the merged-to branch keeps the commit history alive and there's no longer any need to keep the old label around. If you delete a branch without merging it, of course, any content and commit history exclusive to that branch is lost.

Note: See TracWiki for help on using the wiki.