Skip to content
This repository was archived by the owner on Feb 8, 2021. It is now read-only.

Commit bbda7ed

Browse files
authored
Merge pull request #211 from carmark/push
support push sub-command
2 parents 1ed5d3f + 2b743ec commit bbda7ed

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

api/client/push.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,19 @@ package client
33
import (
44
"io"
55

6-
"golang.org/x/net/context"
7-
86
"github.com/docker/engine-api/types"
97
Cli "github.com/hyperhq/hypercli/cli"
108
"github.com/hyperhq/hypercli/pkg/jsonmessage"
119
flag "github.com/hyperhq/hypercli/pkg/mflag"
1210
"github.com/hyperhq/hypercli/reference"
1311
"github.com/hyperhq/hypercli/registry"
12+
"golang.org/x/net/context"
1413
)
1514

1615
// CmdPush pushes an image or repository to the registry.
1716
//
18-
// Usage: docker push NAME[:TAG]
19-
func (cli *DockerCli) Push(args ...string) error {
17+
// Usage: hyper push NAME[:TAG]
18+
func (cli *DockerCli) CmdPush(args ...string) error {
2019
cmd := Cli.Subcmd("push", []string{"NAME[:TAG]"}, Cli.DockerCommands["push"].Description, true)
2120
addTrustedFlags(cmd, false)
2221
cmd.Require(flag.Exact, 1)

cli/common.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ var dockerCommands = []Command{
5151
{"port", "List port mappings or a specific mapping for the CONTAINER"},
5252
{"ps", "List containers"},
5353
{"pull", "Pull an image or a repository from a registry"},
54-
//{"push", "Push an image or a repository to a registry"},
54+
{"push", "Push an image or a repository to a registry"},
5555
{"rename", "Rename a container"},
5656
{"restart", "Restart a container"},
5757
{"rm", "Remove one or more containers"},

0 commit comments

Comments
 (0)