Create a job matrix
This commit is contained in:
parent
52d1540ad6
commit
5bc43aa0c5
1 changed files with 21 additions and 11 deletions
32
.github/workflows/cli-release.yml
vendored
32
.github/workflows/cli-release.yml
vendored
|
@ -11,29 +11,39 @@ on:
|
|||
- "cli-v*"
|
||||
|
||||
jobs:
|
||||
release-linux-amd64:
|
||||
draft-release:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Create a draft GitHub release
|
||||
uses: ncipollo/release-action@v1
|
||||
with:
|
||||
prerelease: true
|
||||
draft: true
|
||||
allowUpdates: true
|
||||
updateOnlyUnreleased: true
|
||||
|
||||
- name: Build go binaries and upload to the release
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
needs: draft-release
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
goos: [linux, windows, darwin]
|
||||
arch: ["386", amd64, arm64]
|
||||
exclude:
|
||||
- goarch: "386"
|
||||
goos: darwin
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Build binaries and add to the release
|
||||
uses: wangyoucao577/go-release-action@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
asset_name: ente-${{ github.ref_name }}-linux-amd64
|
||||
goos: ${{ matrix.goos }}
|
||||
goarch: ${{ matrix.goarch }}
|
||||
asset_name: ente-${{ github.ref_name }}-${{ matrix.goos }}-${{ matrix.goarch }}
|
||||
release_name: ${{ github.ref_name }}
|
||||
goversion: "1.20"
|
||||
project_path: "./cli"
|
||||
sha256sum: true
|
||||
goos: linux
|
||||
goarch: amd64
|
||||
|
|
Loading…
Add table
Reference in a new issue