This commit is contained in:
@@ -58,8 +58,13 @@ jobs:
|
||||
CGO_ENABLED=0 GOOS=linux GOARCH="${arch}" \
|
||||
go build -trimpath -ldflags "${LDFLAGS}" \
|
||||
-o "zhanlu-proxy-linux-${arch}" ./cmd/zhanlu-proxy
|
||||
|
||||
echo "building windows/${arch}"
|
||||
CGO_ENABLED=0 GOOS=windows GOARCH="${arch}" \
|
||||
go build -trimpath -ldflags "${LDFLAGS}" \
|
||||
-o "zhanlu-proxy-windows-${arch}.exe" ./cmd/zhanlu-proxy
|
||||
done
|
||||
ls -lh zhanlu-proxy-linux-*
|
||||
ls -lh zhanlu-proxy-linux-* zhanlu-proxy-windows-*.exe
|
||||
|
||||
- name: Publish release assets
|
||||
if: startsWith(github.ref, 'refs/tags/v')
|
||||
@@ -80,10 +85,11 @@ jobs:
|
||||
echo "release id: ${RELEASE_ID}"
|
||||
|
||||
for arch in amd64 arm64; do
|
||||
f="zhanlu-proxy-linux-${arch}"
|
||||
for f in "zhanlu-proxy-linux-${arch}" "zhanlu-proxy-windows-${arch}.exe"; do
|
||||
curl -fsSL -X POST -H "${AUTH}" \
|
||||
-F "attachment=@${f};filename=${f}" \
|
||||
"${API}/releases/${RELEASE_ID}/assets?name=${f}"
|
||||
done
|
||||
done
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
Reference in New Issue
Block a user