From 183014096fdb87811b5051c0a5d2d475ccaabcb3 Mon Sep 17 00:00:00 2001 From: xiaoqidun Date: Wed, 23 Sep 2020 15:10:06 +0800 Subject: [PATCH] =?UTF-8?q?docs(=E6=9B=B4=E6=96=B0=E6=96=87=E6=A1=A3):=20?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=96=87=E6=A1=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 32a0467..b618827 100644 --- a/README.md +++ b/README.md @@ -35,12 +35,12 @@ docker run --rm -it -v "${pwd}:/go/src/app" -w /go/src/app xiaoqidun/goenv ## 在容器内执行命令进行编译 -### 编译windows程序 +### 编译linux程序 ```shell -export GOOS=windows -export GOARCH=amd64 -export CGO_ENABLED=0 -go build -o main_windows_amd64.exe main.go +GOOS=linux +GOARCH=amd64 +CGO_ENABLED=0 +go build -o main_linux_amd64 main.go ``` ### 编译android程序 @@ -52,6 +52,14 @@ export CGO_ENABLED=1 go build -o main_android_arm64 main.go ``` +### 编译windows程序 +```shell +export GOOS=windows +export GOARCH=amd64 +export CGO_ENABLED=0 +go build -o main_windows_amd64.exe main.go +``` + # 编译说明 ## GOOS