I’m working on a git workflow to implement in a small team. The core ideas in the workflow:
- There is a shared project master that all team members can write to
- All development is done exclusively on feature branches
- Feature branches are code reviewed by a team member other than the branch author
- The feature branch is eventually merged into the shared master and the cycle starts again
The article explains the steps in this cycle in detail:
https://github.com/janosgyerik/git-workflows-book/blob/small-team-workflow/chapter05.md
Does this make sense or am I missing something?
0
I like the git flow branching model. The master branch is left alone most of the time, it only contains releases. The develop branch should be stable at all times, and the feature branches can be broken.
You can also combine this with continuous integration by merging develop into your feature branch and your feature branch into develop. Of course you should only merge something into develop when you’re confident that things are working and do not break.
1
I think you are missing the topic Continuous Integration. It should be part of every development setup.
With feature branches you have the problem, that you don’t integrate continously, but only after a feature is completed.
If the feature branched is short lived, this might be acceptable, but it is definetly something one should consider.
Another alternativ is to setup CI builds for each feature branch. This sure does help, but it isn’t integration. This becomes obvious once you find your first bug that doesn’t appear in Feature A nor Feature B, but in the moment where you integrate Feature A&B
A third alternative is to make merging in some integration branch part of the CI build. This is true integration, and actually works reasonably well with git if the work is somewhat seperated, but causes merge conflicts during the build resulting in failed builds.
8
You can get inspired to gitflow or Twgit.
gitflow summarizes its approach as:
Git extensions to provide high-level repository operations for Vincent
Driessen’s branching model.
Twgit describes itself as follows:
Twgit is a free and open source assisting tools for managing features,
hotfixes and releases on Git repositories. It provides simple,
high-level commands to adopt the branching model describes in our
documentation. Supported OS: Debian/Ubuntu Linux, Mac OS X.
Both tools are available from github.
0