deprecate skopeo layers

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
This commit is contained in:
Antonio Murdaca 2016-11-02 09:22:34 +01:00
parent 2c5532746f
commit b3b322e10b
No known key found for this signature in database
GPG Key ID: B2BEAD150DE936B9

View File

@ -2,7 +2,9 @@ package main
import (
"errors"
"fmt"
"io/ioutil"
"os"
"strings"
"github.com/containers/image/directory"
@ -12,14 +14,14 @@ import (
"github.com/urfave/cli"
)
// TODO(runcom): document args and usage
var layersCmd = cli.Command{
Name: "layers",
Usage: "Get layers of IMAGE-NAME",
ArgsUsage: "IMAGE-NAME [LAYER...]",
Action: func(c *cli.Context) error {
fmt.Fprintln(os.Stderr, `DEPRECATED: skopeo layers is deprecated in favor of skopeo copy`)
if c.NArg() == 0 {
return errors.New("please specify an image")
return errors.New("Usage: layers imageReference [layer...]")
}
rawSource, err := parseImageSource(c, c.Args()[0], []string{
// TODO: skopeo layers only supports these now