git checkout -b feature-xyz

Category: Git - Core

git checkout -b feature-xyz

Create and switch to a new branch in one step

Creates a new branch and switches to it in one step.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.