I am starting a new Project and it has been decided that we shall use git for our version control.
It is a project which involves development of multiple components / Microservices from scratch.
To address the complexities in our organisation where we have junior developers, senior developers, dev leads, architects etc., I was looking to use a git workflow based more or less on gitflow, so that we can ensure that developers can work on feature branches and before moving on to the develop branch, we have some code review process in place. I want to have master branch which corresponds to the production / production ready code and release branches to signify the current release in progress.
It is an agile project so my idea is to have develop branch corresponding to the sprint code (unit tested and reviewed) and the release branch corresponding to the release (=3 sprints).
The only issue I am facing is how to define the master branch and the relationship between master and develop at the beginning.
Since it is a new dev project, we begin with no production code and everything would basically start from feature branches, move to develop, release and then the master when we have the production ready code.
Any suggestions on how to handle this in a good way and also, is this a good idea
Thanks in advance
First create a master branch and then from the master branch create other branches. For your reference, I find this gitflow branching model diagram helpful and have successfully in multiple projects.
Don't over do it. First start off with the simplest branching strategy and then depending upon the complexity and need you may create or adapt to more complex branching strategy.