DockerCLI/cli
Kevin Alvarez d93d78588d
load plugin command stubs when required
We are currently loading plugin command stubs for every
invocation which still has a significant performance hit.
With this change we are doing this operation only if cobra
completion arg request is found.

- 20.10.23: `docker --version` takes ~15ms
- 23.0.1: `docker --version` takes ~93ms

With this change `docker --version` takes ~9ms

Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
(cherry picked from commit c39c711a18)
2023-03-31 16:38:01 +02:00
..
command Merge pull request #4107 from thaJeztah/23.0_backport_size_flag_ps 2023-03-21 17:54:09 +01:00
compose cli/compose: use strings.Cut 2022-12-29 15:19:31 +01:00
config Fix issue where one bad credential helper causes none to be returned 2023-01-31 17:14:30 +01:00
connhelper Fix ssh process killed when context is done 2022-12-04 22:09:17 -05:00
context context: avoid corrupt file writes 2023-03-01 16:14:03 +01:00
debug updated vendoring 2017-09-01 19:41:06 -04:00
flags cmd: set double quotes as code delimiter 2023-01-06 19:15:33 +01:00
manifest manifest: save raw manifest content on download 2023-01-27 13:56:17 +00:00
registry/client manifest: add support for oci image types 2023-01-27 13:51:57 +00:00
streams update docker, replace github.com/docker/pkg/term, github.com/docker/pkg/mount 2020-04-22 17:16:13 +02:00
trust format code with gofumpt 2022-09-30 11:59:11 +02:00
version Move versioning variables to a separate package. 2019-01-29 11:26:40 +00:00
winresources Use goversioninfo to create Windows Version Info 2021-10-11 16:54:22 +02:00
cobra.go load plugin command stubs when required 2023-03-31 16:38:01 +02:00
cobra_test.go cli: use custom annotation for aliases 2022-06-28 17:32:09 +02:00
error.go Import docker/docker/cli 2017-04-17 17:40:59 -04:00
required.go format (GoDoc) comments with Go 1.19 to prepare for go updates 2022-07-19 19:10:16 +02:00
required_test.go cli: remove deprecated io/ioutil 2022-02-25 15:42:19 +01:00