Browse code

Fix a bit typos

Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>

yuexiao-wang authored on 2016/12/09 02:35:32
Showing 9 changed files
... ...
@@ -3,6 +3,6 @@ package api
3 3
 // MinVersion represents Minimum REST API version supported
4 4
 // Technically the first daemon API version released on Windows is v1.25 in
5 5
 // engine version 1.13. However, some clients are explicitly using downlevel
6
-// APIs (eg docker-compose v2.1 file format) and that is just too restrictive.
6
+// APIs (e.g. docker-compose v2.1 file format) and that is just too restrictive.
7 7
 // Hence also allowing 1.24 on Windows.
8 8
 const MinVersion string = "1.24"
... ...
@@ -317,7 +317,7 @@ type HostConfig struct {
317 317
 
318 318
 	// Applicable to Windows
319 319
 	ConsoleSize [2]uint   // Initial console size (height,width)
320
-	Isolation   Isolation // Isolation technology of the container (eg default, hyperv)
320
+	Isolation   Isolation // Isolation technology of the container (e.g. default, hyperv)
321 321
 
322 322
 	// Contains container's resources (cgroups, ulimits)
323 323
 	Resources
... ...
@@ -229,7 +229,7 @@ func (container *Container) SetupWorkingDirectory(rootUID, rootGID int) error {
229 229
 
230 230
 	container.Config.WorkingDir = filepath.Clean(container.Config.WorkingDir)
231 231
 
232
-	// If can't mount container FS at this point (eg Hyper-V Containers on
232
+	// If can't mount container FS at this point (e.g. Hyper-V Containers on
233 233
 	// Windows) bail out now with no action.
234 234
 	if !container.canMountFS() {
235 235
 		return nil
... ...
@@ -79,7 +79,7 @@ func init() {
79 79
 		containerStoragePath = strings.Replace(containerStoragePath, `/`, `\`, -1)
80 80
 		// On Windows, extract out the version as we need to make selective
81 81
 		// decisions during integration testing as and when features are implemented.
82
-		// eg in "10.0 10550 (10550.1000.amd64fre.branch.date-time)" we want 10550
82
+		// e.g. in "10.0 10550 (10550.1000.amd64fre.branch.date-time)" we want 10550
83 83
 		windowsDaemonKV, _ = strconv.Atoi(strings.Split(info.KernelVersion, " ")[1])
84 84
 	} else {
85 85
 		volumesConfigPath = strings.Replace(volumesConfigPath, `\`, `/`, -1)
... ...
@@ -661,7 +661,7 @@ func TarWithOptions(srcPath string, options *TarOptions) (io.ReadCloser, error)
661 661
 				if skip {
662 662
 					// If we want to skip this file and its a directory
663 663
 					// then we should first check to see if there's an
664
-					// excludes pattern (eg !dir/file) that starts with this
664
+					// excludes pattern (e.g. !dir/file) that starts with this
665 665
 					// dir. If so then we can't skip this dir.
666 666
 
667 667
 					// Its not a dir then so we can just return/skip.
... ...
@@ -42,7 +42,7 @@ type ServerHeader struct {
42 42
 }
43 43
 
44 44
 // ParseServerHeader extracts pieces from an HTTP server header
45
-// which is in the format "docker/version (os)" eg docker/1.8.0-dev (windows).
45
+// which is in the format "docker/version (os)" e.g. docker/1.8.0-dev (windows).
46 46
 func ParseServerHeader(hdr string) (*ServerHeader, error) {
47 47
 	matches := headerRegexp.FindStringSubmatch(hdr)
48 48
 	if len(matches) != 4 {
... ...
@@ -21,7 +21,7 @@ const allowV1PluginsFallback bool = true
21 21
 
22 22
 /* defaultAPIVersion is the version of the plugin API for volume, network,
23 23
    IPAM and authz. This is a very stable API. When we update this API, then
24
-   pluginType should include a version. eg "networkdriver/2.0".
24
+   pluginType should include a version. e.g. "networkdriver/2.0".
25 25
 */
26 26
 const defaultAPIVersion string = "1.0"
27 27
 
... ...
@@ -336,7 +336,7 @@ func compareRandomizedStrings(a, b, c, d string) error {
336 336
 // setupPlatformVolume takes two arrays of volume specs - a Unix style
337 337
 // spec and a Windows style spec. Depending on the platform being unit tested,
338 338
 // it returns one of them, along with a volume string that would be passed
339
-// on the docker CLI (eg -v /bar -v /foo).
339
+// on the docker CLI (e.g. -v /bar -v /foo).
340 340
 func setupPlatformVolume(u []string, w []string) ([]string, string) {
341 341
 	var a []string
342 342
 	if runtime.GOOS == "windows" {
... ...
@@ -216,7 +216,7 @@ func ParseMountRaw(raw, volumeDriver string) (*MountPoint, error) {
216 216
 	case 2:
217 217
 		if ValidMountMode(arr[1]) {
218 218
 			// Destination + Mode is not a valid volume - volumes
219
-			// cannot include a mode. eg /foo:rw
219
+			// cannot include a mode. e.g. /foo:rw
220 220
 			return nil, errInvalidSpec(raw)
221 221
 		}
222 222
 		// Host Source Path or Name + Destination