code: func NewRmCommand(dockerCli command.Cli) *cobra.Command {
  	var opts rmOptions
  
  	cmd := &cobra.Command{
  		Use:   "rm [OPTIONS] CONTAINER [CONTAINER...]",
  		Short: "Remove one or more containers",
  		Args:  cli.RequiresMinArgs(1),
  		RunE: func(cmd *cobra.Command, args []string) error {
  			opts.containers = args
  			return runRm(dockerCli, &opts)
  		},
  	}
  
  	flags := cmd.Flags()
  	flags.BoolVarP(&opts.rmVolumes, "volumes", "v", false, "Remove the volumes associated with the container")
  	flags.BoolVarP(&opts.rmLink, "link", "l", false, "Remove the specified link")
  	flags.BoolVarP(&opts.force, "force", "f", false, "Force the removal of a running container (uses SIGKILL)")
  	return cmd
  }
docs: // NewRmCommand creates a new cobra.Command for `docker rm`