mirror of
https://github.com/denisidoro/navi
synced 2024-11-22 03:23:05 +00:00
52 lines
1.6 KiB
YAML
52 lines
1.6 KiB
YAML
name: Publish
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- "*"
|
|
|
|
jobs:
|
|
binary:
|
|
name: Publish ${{ matrix.target }}
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
include:
|
|
- os: macos-latest
|
|
target: x86_64-apple-darwin
|
|
- os: ubuntu-latest
|
|
target: x86_64-unknown-linux-musl
|
|
- os: ubuntu-latest
|
|
target: x86_64-pc-windows-gnu
|
|
- os: ubuntu-latest
|
|
target: armv7-unknown-linux-musleabihf
|
|
- os: ubuntu-latest
|
|
target: armv7-linux-androideabi
|
|
- os: ubuntu-latest
|
|
target: aarch64-linux-android
|
|
- os: ubuntu-latest
|
|
target: aarch64-unknown-linux-gnu
|
|
- os: macos-latest
|
|
target: aarch64-apple-darwin
|
|
steps:
|
|
- uses: hecrj/setup-rust-action@v1.3.4
|
|
with:
|
|
rust-version: stable
|
|
- uses: actions/checkout@v1
|
|
- name: Install target
|
|
id: installtarget
|
|
run: rustup target add ${{ matrix.target }}
|
|
- name: Build
|
|
id: build
|
|
run: scripts/dot rust release ${{ matrix.target }}
|
|
- name: Get the version
|
|
id: get_version
|
|
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//}
|
|
- name: Upload binaries to release
|
|
uses: svenstaro/upload-release-action@v1-release
|
|
with:
|
|
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
|
file: target/tar/navi.${{ steps.build.outputs.EXTENSION }}
|
|
tag: ${{ github.ref }}
|
|
asset_name: navi-${{ steps.get_version.outputs.VERSION }}-${{ matrix.target }}.${{ steps.build.outputs.EXTENSION }}
|