]> git.ipfire.org Git - thirdparty/git.git/commit
completion: factor out __git_resolve_builtins
authorRubén Justo <rjusto@gmail.com>
Sat, 2 Mar 2024 15:52:03 +0000 (16:52 +0100)
committerJunio C Hamano <gitster@pobox.com>
Sun, 3 Mar 2024 22:21:39 +0000 (14:21 -0800)
commit476a236e72d7ad0d2a5237faeaa439b1054e80a5
treed51282770671d50ff6746087f8f4b14edb8679f9
parent3fec482b5f7f2f13c7465cf79062440a84233d14
completion: factor out __git_resolve_builtins

We're going to use the result of "git xxx --git-completion-helper" not
only for feeding COMPREPLY.

Therefore, factor out the execution and the caching of its results in
__gitcomp_builtin, to a new function __git_resolve_builtins.

While we're here, move an important comment we have in the function to
its header, so it gains visibility.

Signed-off-by: Rubén Justo <rjusto@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/completion/git-completion.bash