You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
>, giving it the name of the module your code will be in (here, just use
107
+
"hello"):
108
+
</p>
109
+
110
+
<pre>
111
+
$ go mod init hello
112
+
go: creating new go.mod: module hello
113
+
</pre
114
+
>
115
+
</li>
116
+
92
117
<li>
93
118
In your text editor, create a file hello.go in which to write your code.
94
119
</li>
@@ -224,26 +249,15 @@ <h2 id="call">Call code in an external package</h2>
224
249
</li>
225
250
226
251
<li>
227
-
Put your own code in a module for tracking dependencies.
252
+
Add new module requirements and sums.
228
253
229
254
<p>
230
-
When your code imports packages from another module, a go.mod file lists
231
-
the specific modules and versions providing those packages. That file
232
-
stays with your code, including in your source code repository.
255
+
Go will add the <code>quote</code> module as a requirement, as well as a go.sum file for use in authenticating the module. For more, see <ahref="https://golang.org/cmd/go/#hdr-Module_authentication_using_go_sum">Module authentication using go.sum</a>.
0 commit comments