]> git.ipfire.org Git - thirdparty/git.git/commit
builtin/config: move legacy mode into its own function
authorPatrick Steinhardt <ps@pks.im>
Wed, 15 May 2024 06:41:43 +0000 (08:41 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 May 2024 14:17:52 +0000 (07:17 -0700)
commit0336d0055c4a15916fe6fabbe8031efa042412c0
treea62e4eb87505fdfb6ce068c0b0ef0318365ac402
parenta577d2f1a93ecfafbedd5a30cc15e4180253f04d
builtin/config: move legacy mode into its own function

In `cmd_config()` we first try to parse the provided arguments as
subcommands and, if this is successful, call the respective functions
of that subcommand. Otherwise we continue with the "legacy" mode that
uses implicit actions and/or flags.

Disentangle this by moving the legacy mode into its own function. This
allows us to move the options into the respective functions and clearly
separates concerns.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/config.c