Skip to content

Commit

Permalink
feat: more release build target
Browse files Browse the repository at this point in the history
  • Loading branch information
greenhat616 committed Sep 15, 2023
1 parent 014cb98 commit af2994a
Showing 1 changed file with 23 additions and 4 deletions.
27 changes: 23 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
jobs:
create_release :
if: startsWith(github.ref, 'refs/tags/')
name: release ${{ matrix.target }}
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Checkout Code
Expand All @@ -34,7 +34,7 @@ jobs:
token: ${{ github.token }}

release:
name: release
name: Build Release
needs: create_release
runs-on: ${{ matrix.os }}
strategy:
Expand All @@ -43,17 +43,27 @@ jobs:
- target: x86_64-apple-darwin
os: macos-latest
archive: tar.gz
- target: x86_64-pc-windows-gnu
- target: aarch64-apple-darwin
os: macos-latest
archive: tar.gz
- target: x86_64-pc-windows-msvc
os: windows-latest
ext: .exe
archive: zip
- target: x86_64-pc-windows-msvc
- target: aarch64-pc-windows-msvc
os: windows-latest
ext: .exe
archive: zip
- target: i686-pc-windows-msvc
os: windows-latest
ext: .exe
archive: zip
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
archive: tar.gz
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
archive: tar.gz
- target: x86_64-unknown-linux-musl
os: ubuntu-latest
archive: tar.gz
Expand All @@ -65,6 +75,15 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Cargo build
run: |
rustup toolchain install nightly --profile minimal -t ${{ matrix.target }}
Expand Down

0 comments on commit af2994a

Please sign in to comment.