Skip to content

Instantly share code, notes, and snippets.

View jakobgerstenlauer's full-sized avatar

Jakob Gerstenlauer jakobgerstenlauer

  • Stuttgart, Germany
View GitHub Profile

Git Feature Branch Best Practices

  1. Checkout the master branch and update it. Only allow fast-forward-merge.
    • $ git checkout master
    • $ git pull -ff-only
  2. Create a new feature branch based on the current master branch.
    • $ git checkout -b feature_branch
  3. Back-up your local feature branch.
    • $ git push --set-upstream origin feature_branch

Later it is sufficient to write: