mirror of
https://github.com/golang/go.git
synced 2025-05-05 15:43:04 +00:00
Adding CLI commands for Windows cmd.exe, if PowerShell not available
parent
642953dd86
commit
a49df76d0e
@ -20,6 +20,14 @@ func main() {
|
||||
$ GOOS=windows GOARCH=386 go build -o hello.exe hello.go
|
||||
```
|
||||
|
||||
In cmd.exe instead of PowerShell:
|
||||
|
||||
```go
|
||||
$ set GOOS=windows
|
||||
$ set GOARCH=386
|
||||
$ go build -o hello.exe hello.go
|
||||
```
|
||||
|
||||
You can now run `hello.exe` on a Windows machine near you.
|
||||
|
||||
Note that the command above will silently rebuild most of standard library, and for this reason will be quite slow. To speed-up the process, you can install all the windows-amd64 standard packages on your system with
|
||||
|
Loading…
x
Reference in New Issue
Block a user