diff --git a/cli/command/checkpoint/cmd.go b/cli/command/checkpoint/cmd.go index 2a698e74e5..14154b2627 100644 --- a/cli/command/checkpoint/cmd.go +++ b/cli/command/checkpoint/cmd.go @@ -7,12 +7,18 @@ import ( ) // NewCheckpointCommand returns the `checkpoint` subcommand (only in experimental) -func NewCheckpointCommand(dockerCli command.Cli) *cobra.Command { +// +// Deprecated: Do not import commands directly. They will be removed in a future release. +func NewCheckpointCommand(dockerCLI command.Cli) *cobra.Command { + return newCheckpointCommand(dockerCLI) +} + +func newCheckpointCommand(dockerCLI command.Cli) *cobra.Command { cmd := &cobra.Command{ Use: "checkpoint", Short: "Manage checkpoints", Args: cli.NoArgs, - RunE: command.ShowHelp(dockerCli.Err()), + RunE: command.ShowHelp(dockerCLI.Err()), Annotations: map[string]string{ "experimental": "", "ostype": "linux", @@ -20,9 +26,9 @@ func NewCheckpointCommand(dockerCli command.Cli) *cobra.Command { }, } cmd.AddCommand( - newCreateCommand(dockerCli), - newListCommand(dockerCli), - newRemoveCommand(dockerCli), + newCreateCommand(dockerCLI), + newListCommand(dockerCLI), + newRemoveCommand(dockerCLI), ) return cmd } diff --git a/cli/command/commands/commands.go b/cli/command/commands/commands.go index c7a55ec16d..7bce95eafd 100644 --- a/cli/command/commands/commands.go +++ b/cli/command/commands/commands.go @@ -47,6 +47,7 @@ func AddCommands(cmd *cobra.Command, dockerCli command.Cli) { builder.NewBakeStubCommand(dockerCli), //nolint:staticcheck // TODO: Remove when migration to cli/internal/commands.Register is complete. (see #6283) builder.NewBuilderCommand(dockerCli), + //nolint:staticcheck // TODO: Remove when migration to cli/internal/commands.Register is complete. (see #6283) checkpoint.NewCheckpointCommand(dockerCli), container.NewContainerCommand(dockerCli), context.NewContextCommand(dockerCli),