From 71af945cf2ffab4b96a50d1d3f67259983fb07f0 Mon Sep 17 00:00:00 2001 From: Waldir Pimenta Date: Thu, 8 Nov 2018 09:49:50 +0000 Subject: [PATCH] git-branch: add example to specify starting point (#2563) --- pages/common/git-branch.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pages/common/git-branch.md b/pages/common/git-branch.md index a4848425ed..ea3ec2f039 100644 --- a/pages/common/git-branch.md +++ b/pages/common/git-branch.md @@ -14,6 +14,10 @@ `git branch {{branch_name}}` +- Create new branch based on a specific commit: + +`git branch {{branch_name}} {{commit_hash}}` + - Rename a branch (must not have it checked out to do this): `git branch -m {{old_branch_name}} {{new_branch_name}}`