What is a feature branch?

What is a feature branch?

A feature branch is a copy of the main codebase where an individual or team of software developers can work on a new feature until it is complete. To avoid overriding each other’s changes, engineers create their own copy of the codebase, called branches.

How does feature branch work?

A feature branch is a source code branching pattern where a developer opens a branch when she starts working on a new feature. This has the consequence that two people, working on different feature branches, do not integrate their work until the second one merges their work into the common codebase.

What’s the difference between Main Branch and feature branch in Git?

Git makes no technical distinction between the main branch and feature branches, so developers can edit, stage, and commit changes to a feature branch. In addition, feature branches can (and should) be pushed to the central repository. This makes it possible to share a feature with other developers without touching any official code.

Can a feature branch diverge from the main branch?

But branches need not live in solitary confinement. Developers can easily pull down changes from other developers to collaborate on features and ensure their private branch doesn’t diverge too far from the main. Branches aren’t just good for feature work.

Which is newer, the development branch or the master branch?

Both are common approaches, and have their pros and cons. If developers are working on feature branches, and then merging those into master when they’re done, that means there’s a period of time where features/fixes are being merged into master and the master branch is actually newer than production.

What’s the difference between a release and a develop branch?

feature: All features / new functions / major refactorings are done in feature branches, which branch off and are merged back into the develop branch (usually after some kind of peer review). release: When enough features have accumulated or the next release time frame comes near, a new release branch is branched off develop.