# workflow, step by step:
git checkout srcBranch # where new branch will be created from
git branch newBranch # newBranch is created from srcBranch
git checkout newBranch # switch from srcBranch to newBranch
# in a single line:
git checkout -b newBranch srcBranch
git checkout -b newBranch # srcBranch is optional if already checked out