DockerCLI/cli/command/network
Sebastiaan van Stijn 99fb2c1baa
Hide "builder" and "network" commands on old API versions
- The `/build/prune` endpoint was added in API v1.31
- The `/network` endpoints were added in API v1.21

This patch hides these commands on older API versions

Before this change:

```
DOCKER_API_VERSION=1.0 docker

...

Management Commands:
  builder     Manage builds
  container   Manage containers
  image       Manage images
  manifest    Manage Docker image manifests and manifest lists
  network     Manage networks
  system      Manage Docker
  trust       Manage trust on Docker images
```

After this change

```
DOCKER_API_VERSION=1.0 docker

...

Management Commands:
  container   Manage containers
  image       Manage images
  manifest    Manage Docker image manifests and manifest lists
  system      Manage Docker
  trust       Manage trust on Docker images
```

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2019-01-30 01:06:09 +01:00
..
testdata use sortorder lib for sorting network list output 2018-08-08 12:06:59 -04:00
client_test.go Switch from x/net/context to context 2018-05-11 16:49:43 -07:00
cmd.go Hide "builder" and "network" commands on old API versions 2019-01-30 01:06:09 +01:00
connect.go Switch from x/net/context to context 2018-05-11 16:49:43 -07:00
connect_test.go Update tests to use gotest.tools 👼 2018-06-08 18:24:26 +02:00
create.go Switch from x/net/context to context 2018-05-11 16:49:43 -07:00
create_test.go Update tests to use gotest.tools 👼 2018-06-08 18:24:26 +02:00
disconnect.go Switch from x/net/context to context 2018-05-11 16:49:43 -07:00
disconnect_test.go Update tests to use gotest.tools 👼 2018-06-08 18:24:26 +02:00
formatter.go formatter package heavy refactoring 2018-10-23 17:05:44 +02:00
formatter_test.go formatter package heavy refactoring 2018-10-23 17:05:44 +02:00
inspect.go Switch from x/net/context to context 2018-05-11 16:49:43 -07:00
list.go formatter package heavy refactoring 2018-10-23 17:05:44 +02:00
list_test.go refactor network list unit tests to table-driven style 2018-08-02 14:07:06 -04:00
prune.go build: add options to builder prune 2018-09-05 00:01:16 +00:00
remove.go Switch from x/net/context to context 2018-05-11 16:49:43 -07:00