HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

gox — Cross-compile Go programs. More information: <https://github.com/mitchellh/gox>.

Submitted by: @import:tldr-pages··
0
Viewed 0 times
programscommandgoxcompilecliinformationcrossmore

Problem

How to use the gox command: Cross-compile Go programs. More information: <https://github.com/mitchellh/gox>.

Solution

gox — Cross-compile Go programs. More information: <https://github.com/mitchellh/gox>.

Compile Go program in the current directory for all operating systems and architecture combinations:
gox


Download and compile a Go program from a remote URL:
gox {{url_1 url_2 ...}}


Compile current directory for a particular operating system:
gox -os="{{os}}"


Compile current directory for a single operating system and architecture combination:
gox -osarch="{{os}}/{{arch}}"

Code Snippets

Compile Go program in the current directory for all operating systems and architecture combinations

gox

Download and compile a Go program from a remote URL

gox {{url_1 url_2 ...}}

Compile current directory for a particular operating system

gox -os="{{os}}"

Compile current directory for a single operating system and architecture combination

gox -osarch="{{os}}/{{arch}}"

Context

tldr-pages: common/gox

Revisions (0)

No revisions yet.