Add a few more Go-related commands
This commit is contained in:
parent
b23050b4c9
commit
8445da5817
|
@ -28,6 +28,9 @@ go version
|
|||
|
||||
# Find where the current module would be installed to.
|
||||
go list -f '{{.Target}}'
|
||||
|
||||
# List environment information, including where packages are installed via go get.
|
||||
go env
|
||||
```
|
||||
|
||||
## Requirements
|
||||
|
@ -37,6 +40,9 @@ go mod edit -replace example.com/greetings=../greetings
|
|||
|
||||
# Get an external module and add to go.mod require.
|
||||
go get golang.org/x/example
|
||||
|
||||
# Get dependencies for code in the current directory (already added as an import).
|
||||
go get .
|
||||
```
|
||||
|
||||
## Workspaces
|
||||
|
|
Loading…
Reference in New Issue