From 88f8809909690c25c8f8468fb13f4efcf4d88017 Mon Sep 17 00:00:00 2001 From: chaunsin <906591446@qq.com> Date: Tue, 26 Nov 2024 21:01:35 +0800 Subject: [PATCH] ci: static complie binary --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 838068b..d5719ee 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -56,7 +56,7 @@ jobs: run: | mkdir -p output xgo --targets=darwin-10.14/*,windows-6.1/*,linux/amd64,linux/arm64,linux/mips64,linux/mips64le,linux/ppc64le,linux/riscv64 \ - --ldflags "-linkmode "external" -extldflags "-static" -s -w -X 'main.BuildTime=${{ env.BUILD_TIME }}' -X 'main.Version=${{github.ref_name}}' -X 'main.Commit=${{ env.COMMIT_HASH }}'" \ + --ldflags "-extldflags "-static" -s -w -X 'main.BuildTime=${{ env.BUILD_TIME }}' -X 'main.Version=${{github.ref_name}}' -X 'main.Commit=${{ env.COMMIT_HASH }}'" \ -out output/ncmctl ./cmd/ncmctl/main.go echo "Build output:" tree ./output