diff --git a/doc/code.html b/doc/code.html index 4e8c54a1c52d9..b6d41ef68ca16 100644 --- a/doc/code.html +++ b/doc/code.html @@ -44,18 +44,16 @@

Overview

Workspaces

-A workspace is a directory hierarchy with three directories at its root: +A workspace is a directory hierarchy with two directories at its root:

-The go tool builds source packages and installs the resulting -binaries to the pkg and bin directories. +The go tool builds and installs binaries to the bin directory.

@@ -72,10 +70,6 @@

Workspaces

bin/ hello # command executable outyet # command executable -pkg/ - linux_amd64/ - github.com/golang/example/ - stringutil.a # package object src/ github.com/golang/example/ .git/ # Git repository metadata @@ -374,9 +368,8 @@

Your first library

-This won't produce an output file. To do that, you must use go -install, which places the package object inside the pkg -directory of the workspace. +This won't produce an output file. +Instead it saves the compiled package in the local build cache.

@@ -400,19 +393,13 @@

Your first library

-Whenever the go tool installs a package or binary, it also -installs whatever dependencies it has. -So when you install the hello program +Install the hello program:

 $ go install github.com/user/hello
 
-

-the stringutil package will be installed as well, automatically. -

-

Running the new version of the program, you should see a new, reversed message:

@@ -429,10 +416,6 @@

Your first library

 bin/
     hello                 # command executable
-pkg/
-    linux_amd64/          # this will reflect your OS and architecture
-        github.com/user/
-            stringutil.a  # package object
 src/
     github.com/user/
         hello/
@@ -441,22 +424,6 @@ 

Your first library

reverse.go # package source
-

-Note that go install placed the stringutil.a object -in a directory inside pkg/linux_amd64 that mirrors its source -directory. -This is so that future invocations of the go tool can find the -package object and avoid recompiling the package unnecessarily. -The linux_amd64 part is there to aid in cross-compilation, -and will reflect the operating system and architecture of your system. -

- -

-Go command executables are statically linked; the package objects need not -be present to run Go programs. -

- -

Package names

@@ -597,12 +564,6 @@

Remote packages

 bin/
     hello                           # command executable
-pkg/
-    linux_amd64/
-        github.com/golang/example/
-            stringutil.a            # package object
-        github.com/user/
-            stringutil.a            # package object
 src/
     github.com/golang/example/
 	.git/                       # Git repository metadata