summaryrefslogtreecommitdiff
path: root/builtin/commit-graph.c
diff options
context:
space:
mode:
authorClement Mabileau <mabileau.clement@gmail.com>2023-04-05 11:43:20 +0000
committerJunio C Hamano <gitster@pobox.com>2023-04-06 13:11:26 -0700
commit4c643fb321db00a9c79e2dcd1fd033681333584b (patch)
tree5810a441da4e343975facca1d61fd1b92f086e36 /builtin/commit-graph.c
parentae73b2c8f1da39c39335ee76a0f95857712c22a7 (diff)
branch: improve error log on branch not found by checking remotes refs
New git users may want to locally delete remote-tracking branches but don't really understand how they are distinguished from branches by git. Then one may naively try: `git branch -d foo/bar` and get a correct error `branch foo/bar not found` but hard to understand for a newbie, this patch aims to guide one in such case. when failing to delete a branch with `git branch -d <branch>` because of branch not found, try to find a **remote refs** matching `<branch>` and if so, add an hint: `Did you forget --remote?` to the error message Signed-off-by: Clement Mabileau <mabileau.clement@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit-graph.c')
0 files changed, 0 insertions, 0 deletions