Merge pull request #23273 from vdemeester/deprecated-import-3-args

Deprecated the old 3-args form of `docker import`
This commit is contained in:
Sebastiaan van Stijn 2016-06-05 20:02:33 +02:00
commit 3cec900271
2 changed files with 7 additions and 9 deletions

View file

@ -1,7 +1,6 @@
package client
import (
"fmt"
"io"
"os"
@ -31,19 +30,12 @@ func (cli *DockerCli) CmdImport(args ...string) error {
var (
in io.Reader
tag string
src = cmd.Arg(0)
srcName = src
ref = cmd.Arg(1)
changes = flChanges.GetAll()
)
if cmd.NArg() == 3 {
// FIXME(vdemeester) Which version has this been deprecated ? should we remove it ?
fmt.Fprintf(cli.err, "[DEPRECATED] The format 'file|URL|- [REPOSITORY [TAG]]' has been deprecated. Please use file|URL|- [REPOSITORY[:TAG]]\n")
tag = cmd.Arg(2)
}
if src == "-" {
in = cli.in
} else if !urlutil.IsURL(src) {
@ -63,7 +55,6 @@ func (cli *DockerCli) CmdImport(args ...string) error {
options := types.ImageImportOptions{
Message: *message,
Tag: tag,
Changes: changes,
}

View file

@ -14,6 +14,13 @@ weight=80
The following list of features are deprecated in Engine.
### Three argument form in `docker import`
**Deprecated In Release: [v0.6.7](https://github.com/docker/docker/releases/tag/v0.6.7)**
**Removed In Release: [v1.12.0](https://github.com/docker/docker/releases/tag/v1.12.0)**
The `docker import` command format 'file|URL|- [REPOSITORY [TAG]]' is deprecated since November 2013. It's no more supported.
### `-e` and `--email` flags on `docker login`
**Deprecated In Release: [v1.11.0](https://github.com/docker/docker/releases/tag/v1.11.0)**