DEV Community

Discussion on: why branching on git is wrong

Collapse
 
erickmendonca profile image
Erick Mendonça

Communication is key. But we also have another keys:

  • merge your master or parent dev branch into your feature branch often
  • avoid long lived branches

I agree with some suggestions you made, like feature flags. They help a lot to keep the branches short-lived.

Collapse
 
anortef profile image
Adrián Norte

All those premises are the same everywhere I worked that used branches, the result? Years old, thousands of commits behind and totally forgotten branches.

The problem with branching is that it actively requires the developers to be clean.

Collapse
 
erickmendonca profile image
Erick Mendonça

Forgotten branches are forgotten features or projects - they may happen with or without branches. All proposed solutions also require the developers to be clean at something.

I think lack of planning and communication are the main problems in these situations, or at least that was the case on my experiences.