Skip to content

Instantly share code, notes, and snippets.

@zerothabhishek
Last active March 25, 2016 17:56
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zerothabhishek/49e5156417ea230c361e to your computer and use it in GitHub Desktop.
Save zerothabhishek/49e5156417ea230c361e to your computer and use it in GitHub Desktop.
A git process I like

A Git process

  • Developer creates a new branch for every bug-fix or feature
  • Feature branch is always created from master
  • Developer watches master branch for changes. If another team member updates the master, she updates feature branch too.
  • Feature branches are updated using rebase, not by merging
  • Developer deploys the feature branch for demo/QA
  • Another team member reviews code in the feature branch
  • After demo and review passes, developer squash-merges the feature branch in her master, and pushes to the origin master
  • For production-deployment, developer sets a tag on the origin/master, and deploys using the tag

And also,

  • Feature branches are never inter-merged. Feature branches are never created from other feature branches.
  • Long running feature branches are not used. If a feature takes too long, split it in smaller features. Or use feature flips
  • No reusing an old branches. Even if starting work on a old, work-in-progress feature, create a new feature branch.

(Not claiming this is best. This is the one I currently like. Likely to get updates)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment