mirror of
https://github.com/git/git.git
synced 2026-02-18 21:59:08 +00:00
The option parsing of "git checkout" had error checking, dwim and defaulting missing options, all mixed in the code, and issuing an appropriate error message with useful context was getting harder. Reorganize the code and allow giving a proper diagnosis when the user says "git checkout -b -t foo bar" (e.g. "-t" is not a good name for a branch). Will merge to 'next' after squashing the tip two. * nd/checkout-option-parsing-fix: checkout: reorder option handling checkout: move more parameters to struct checkout_opts checkout: pass "struct checkout_opts *" as const pointer Conflicts: builtin/checkout.c