fix
This commit is contained in:
parent
041f87c7bc
commit
eec9984386
66
.github/workflows/release.yaml
vendored
66
.github/workflows/release.yaml
vendored
@ -1,36 +1,46 @@
|
|||||||
on:
|
name: Build And Publish Releases
|
||||||
release:
|
|
||||||
types: [created]
|
|
||||||
|
|
||||||
|
# https://github.com/softprops/action-gh-release/issues/236#issuecomment-1150530128
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
packages: write
|
|
||||||
|
on:
|
||||||
|
# Allow mannual trigger
|
||||||
|
workflow_dispatch:
|
||||||
|
# Trigger on push new tag
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- "v*.*.*"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
releases-matrix:
|
build-and-publish:
|
||||||
name: Release Go Binary
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
# build and publish in parallel: linux/386, linux/amd64, linux/arm64, windows/386, windows/amd64, darwin/amd64, darwin/arm64
|
|
||||||
goos: [linux, windows, darwin]
|
|
||||||
goarch: ["386", amd64, arm64, "arm"]
|
|
||||||
exclude:
|
|
||||||
- goarch: "386"
|
|
||||||
goos: darwin
|
|
||||||
- goarch: arm
|
|
||||||
goos: windows
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- name: Checkout
|
||||||
- uses: wangyoucao577/go-release-action@v1
|
uses: actions/checkout@v4
|
||||||
|
- name: Build Frontend
|
||||||
|
run: |
|
||||||
|
bash build_frontend.sh
|
||||||
|
- name: Compile
|
||||||
|
uses: crazy-max/ghaction-xgo@v3
|
||||||
with:
|
with:
|
||||||
pre_command: bash build_frontend.sh
|
xgo_version: latest
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
go_version: latest
|
||||||
goos: ${{ matrix.goos }}
|
dest: dist
|
||||||
goarch: ${{ matrix.goarch }}
|
prefix: authlibskin
|
||||||
project_path: "./cmd/authlibskin"
|
targets: windows/386,windows/amd64,linux/386,linux/amd64,linux/arm,linux/arm64,darwin/arm64,darwin/amd64
|
||||||
binary_name: "authlibskin"
|
# Show less information
|
||||||
extra_files: LICENSE README.md
|
v: false
|
||||||
executable_compression: upx
|
x: false
|
||||||
build_flags: -tags="redis,sqlite"
|
race: false
|
||||||
ldflags: -w -s
|
ldflags: -s -w
|
||||||
|
buildmode: default
|
||||||
|
trimpath: true
|
||||||
|
|
||||||
|
- name: Publish GitHub Releases
|
||||||
|
uses: softprops/action-gh-release@v1
|
||||||
|
with:
|
||||||
|
name: "authlibskin ${{ github.ref_name }}"
|
||||||
|
files: |
|
||||||
|
./dist/*
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user