Added pkgbuild #38
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Rust static build and publish | |
on: | |
push: | |
tags: | |
- '*' | |
env: | |
CARGO_TERM_COLOR: always | |
BUILD_TARGET: x86_64-unknown-linux-musl | |
BINARY_NAME: rexec | |
jobs: | |
build: | |
name: Build static binary | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: mbrobbel/rustfmt-check@master | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build-musl | |
uses: gmiam/rust-musl-action@master | |
with: | |
args: cargo build --target $BUILD_TARGET --release | |
- uses: actions/upload-artifact@v2 | |
name: Upload artifact | |
with: | |
name: ${{ env.BINARY_NAME }}_x86_64-linux-musl | |
path: target/x86_64-unknown-linux-musl/release/${{ env.BINARY_NAME }} | |
# build_arch: | |
# name: Arch Linux package | |
# runs-on: ubuntu-latest | |
# permissions: | |
# contents: write | |
# steps: | |
# - uses: actions/checkout@v3 | |
# - name: Install latest nightly | |
# uses: actions-rs/toolchain@v1 | |
# with: | |
# toolchain: stable | |
# override: true | |
# target: x86_64-unknown-linux-musl | |
# components: rustfmt | |
# - name: Install cargo-aur | |
# run: cargo install cargo-aur | |
# - name: Build PKGBUILD | |
# uses: actions-rs/cargo@v1 | |
# with: | |
# command: aur | |
# - uses: actions/upload-artifact@v2 | |
# name: Upload artifact PKGBUILD | |
# with: | |
# path: PKGBUILD | |
# name: PKGBUILD | |
release: | |
name: Release binary | |
needs: ["build"] | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/download-artifact@master | |
id: download_binary | |
with: | |
name: ${{ env.BINARY_NAME }}_x86_64-linux-musl | |
path: ${{ env.BINARY_NAME }}_x86_64-linux-musl | |
# - uses: actions/download-artifact@master | |
# id: download_pkgbuild | |
# with: | |
# name: PKGBUILD | |
# path: PKGBUILD | |
- uses: ncipollo/release-action@v1 | |
name: Update release page | |
with: | |
artifacts: "${{ steps.download_binary.outputs.download-path }}/*" | |
allowUpdates: true | |
body: Static build for x86_64-linux using MUSL |