Browse code

fix typos

Signed-off-by: allencloud <allen.sun@daocloud.io>

allencloud authored on 2016/03/26 23:06:45
Showing 4 changed files
... ...
@@ -106,13 +106,13 @@ func (fi *HashedFileInfo) SetHash(h string) {
106 106
 type Backend interface {
107 107
 	// TODO: use digest reference instead of name
108 108
 
109
-	// GetImage looks up a Docker image referenced by `name`.
109
+	// GetImageOnBuild looks up a Docker image referenced by `name`.
110 110
 	GetImageOnBuild(name string) (Image, error)
111
-	// Tag an image with newTag
111
+	// TagImage tags an image with newTag
112 112
 	TagImage(newTag reference.Named, imageName string) error
113
-	// Pull tells Docker to pull image referenced by `name`.
113
+	// PullOnBuild tells Docker to pull image referenced by `name`.
114 114
 	PullOnBuild(ctx context.Context, name string, authConfigs map[string]types.AuthConfig, output io.Writer) (Image, error)
115
-	// ContainerAttach attaches to container.
115
+	// ContainerAttachRaw attaches to container.
116 116
 	ContainerAttachRaw(cID string, stdin io.ReadCloser, stdout, stderr io.Writer, stream bool) error
117 117
 	// ContainerCreate creates a new Docker container and returns potential warnings
118 118
 	ContainerCreate(types.ContainerCreateConfig) (types.ContainerCreateResponse, error)
... ...
@@ -120,13 +120,13 @@ type Backend interface {
120 120
 	ContainerRm(name string, config *types.ContainerRmConfig) error
121 121
 	// Commit creates a new Docker image from an existing Docker container.
122 122
 	Commit(string, *backend.ContainerCommitConfig) (string, error)
123
-	// Kill stops the container execution abruptly.
123
+	// ContainerKill stops the container execution abruptly.
124 124
 	ContainerKill(containerID string, sig uint64) error
125
-	// Start starts a new container
125
+	// ContainerStart starts a new container
126 126
 	ContainerStart(containerID string, hostConfig *container.HostConfig) error
127 127
 	// ContainerWait stops processing until the given container is stopped.
128 128
 	ContainerWait(containerID string, timeout time.Duration) (int, error)
129
-	// ContainerUpdateCmd updates container.Path and container.Args
129
+	// ContainerUpdateCmdOnBuild updates container.Path and container.Args
130 130
 	ContainerUpdateCmdOnBuild(containerID string, cmd []string) error
131 131
 
132 132
 	// ContainerCopy copies/extracts a source FileInfo to a destination path inside a container
... ...
@@ -189,7 +189,7 @@ func Subcmd(name string, synopses []string, description string, exitOnError bool
189 189
 	return flags
190 190
 }
191 191
 
192
-// An StatusError reports an unsuccessful exit by a command.
192
+// StatusError reports an unsuccessful exit by a command.
193 193
 type StatusError struct {
194 194
 	Status     string
195 195
 	StatusCode int
... ...
@@ -151,7 +151,7 @@ func LoadFromReader(configData io.Reader) (*ConfigFile, error) {
151 151
 }
152 152
 
153 153
 // Load reads the configuration files in the given directory, and sets up
154
-// the auth config information and return values.
154
+// the auth config information and returns values.
155 155
 // FIXME: use the internal golang config parser
156 156
 func Load(configDir string) (*ConfigFile, error) {
157 157
 	if configDir == "" {
... ...
@@ -11,7 +11,7 @@ import (
11 11
 // ResolvePath resolves the given path in the container to a resource on the
12 12
 // host. Returns a resolved path (absolute path to the resource on the host),
13 13
 // the absolute path to the resource relative to the container's rootfs, and
14
-// a error if the path points to outside the container's rootfs.
14
+// an error if the path points to outside the container's rootfs.
15 15
 func (container *Container) ResolvePath(path string) (resolvedPath, absPath string, err error) {
16 16
 	// Consider the given path as an absolute path in the container.
17 17
 	absPath = archive.PreserveTrailingDotOrSeparator(filepath.Join(string(filepath.Separator), path), path)