11 Gitflow Workflow
gitflow is a branching model for git created by Vincent Driessen. It forms an elegant mental model that is easy to comprehend and allows team members to develop a shared understanding of branching and releasing processes.
Detailed information can be found on A successful git branching model.
The Git Tower team wrote another detailed description on how to use gitflow with a GUI tool.
Basic usage and effect of git-flow operations on the command line:
In a nutshell:
- use different branches for different purposes
masterholds only releases (and bugfixes)
developholds the latest version under development
all features are developed in single, separate branches called
- only tested features are merged into develop
- these feature branches are merged back into
developafter the feature is finished and tested
Guidelines for gitflow
kb/bestpractices/scc/gitflow-workflow.txt · Last modified: 2020/09/30 15:28 by joerg.hampel
- Create meaningful feature branch names and add your name (or initials) to the branch for easy identification - see branching rules for details
- Each developer should work on no more than one feature branch at any time
- Keep your feature branch synced with develop (as often as possible) to avoid drifting from main code (
git pull develop)
Close your feature branches as soon as the work is finished, not after days when some details are already forgotten. This helps to keep history more readable.Merge the
- i.e. merge develop back into your feature branch
developbranch into your feature branch before finishing it. That way, you can solve any conflicts in your local workspace without breaking anything for the rest of the team.