aboutsummaryrefslogtreecommitdiffstats
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorYutaro Ohno <yutaro.ono.418@gmail.com>2023-01-09 10:47:17 +0000
committerJunio C Hamano <gitster@pobox.com>2023-01-13 09:57:40 -0800
commit9e37969e4b1ef56a2fae6cdf7d5d082c449be1b8 (patch)
treecd22fe933e8426aa844632e66297a3ac6c47ec8d /builtin/commit.c
parentThe sixth batch (diff)
downloadgit-9e37969e4b1ef56a2fae6cdf7d5d082c449be1b8.tar.gz
git-9e37969e4b1ef56a2fae6cdf7d5d082c449be1b8.zip
doc: add "git switch -c" as another option on detached HEAD
In the "DETACHED HEAD" section in the git-checkout doc, it suggests using "git checkout -b <branch-name>" to create a new branch on the detached head. On the other hand, when you checkout a commit that is not at the tip of any named branch (e.g., when you checkout a tag), git suggests using "git switch -c <branch-name>". Add "git switch -c" as another option and mitigate this inconsistency. Signed-off-by: Yutaro Ohno <yutaro.ono.418@gmail.com> Acked-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
0 files changed, 0 insertions, 0 deletions