]> git.ipfire.org Git - thirdparty/git.git/commit
bundle: define subcommand -h in terms of command -h
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>
Thu, 13 Oct 2022 15:38:58 +0000 (17:38 +0200)
committerJunio C Hamano <gitster@pobox.com>
Thu, 13 Oct 2022 16:32:54 +0000 (09:32 -0700)
commitf587d16471a8ce438b7d19afe6f3cdbf5a42cb63
tree3cb06ed3c47f767e1e231fc15841741415ecdc13
parent968a04e4478dff3aacbdd225e436fc2ec1c6a76a
bundle: define subcommand -h in terms of command -h

Avoid repeating the "-h" output for the "git bundle" command, and
instead define the usage of each subcommand with macros, so that the
"-h" output for the command itself can re-use those definitions. See
[1], [2] and [3] for prior art using the same pattern.

1. b25b727494f (builtin/multi-pack-index.c: define common usage with a
   macro, 2021-03-30)
2. 8757b35d443 (commit-graph: define common usage with a macro,
   2021-08-23)
3. 1e91d3faf6c (reflog: move "usage" variables and use macros,
   2022-03-17)

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/bundle.c