One of my topics today was git workflows.
I read something about git flow and the github flow.
In the past I always work with a develop and a master brunch.
After I read about github flow, I was wondering why I always use develop branches:-)
For my customers workflow, I decide to use github flow with release branches.
With release brunches it is possible to ship single features from develop branch to the release branch,
without the need to create a new release.
I know that this is a little dirty, but the customer have little features sometimes, which he wants to have on the production system without a new release of all other features they are already developed and merged. So I can cherrypick this comments to the actual release.
Feature x__x x x
/ \ /\ /\
Master x-----x----------x----x-----x---
\ \ / \ \
Hotfix \ x \ \
\ \ \ \
Release x----x--------x x
pick a single commit from another branch and execute them on the current branch
git cherrypick [commit-id]
Set branch pointer to a specific commit.
git branch -f <branchname> <commit-id>