DEV Community

Discussion on: Git process

Collapse
 
keithdarragh_73 profile image
Keith Darragh

Fair point about the changes not being in the master branch for the time being, but if there are changes which you don't want to release is it not easier to create a release branch from master? This way you can continually add to master and keep it up to date but only release what is necessary? In this scenario a release cut can be taken from a specified commit hash rather than head.

Collapse
 
endy_tj profile image
Endy Tjahjono

Hmm I'm not clear with what you mean. The long lived dev branch is a branch of master. Bug fixes are applied to master using short lived dev branch using the pull request flow (create branch, commit to branch, pull request from branch, squash merge to master). To release we add tag on master, then build from tag.

Thread Thread
 
keithdarragh_73 profile image
Keith Darragh

Instead of using the tag, you can create a release branch which removes the need for a dev branch. How do you manage bug fixes to your master release and propagating those changes back into dev?

Thread Thread
 
endy_tj profile image
Endy Tjahjono

Instead of using the tag, you can create a release branch

Yes, we create branch from the tag in case a version needs patching.

which removes the need for a dev branch

Um no. Put another way, our dev branch uses the same pull request flow but longer lived.

How do you manage bug fixes to your master release and propagating those changes back into dev?

Bug fixes are squash merged from the pull request branches into master, then the dev branch rebase from master.

Thread Thread
 
keithdarragh_73 profile image
Keith Darragh

Yes I understand. I didn’t realise you were gutted a release branch from master as well, I understood you were just using the git tag!

Thread Thread
 
endy_tj profile image
Endy Tjahjono

Off topic, I've been to Belfast twice. Nice city!

Thread Thread
 
keithdarragh_73 profile image
Keith Darragh

It is, come back soon!