This commit is contained in:
Robin Appelman 2021-03-24 20:57:28 +01:00
commit 2d0e93bfce
2 changed files with 80 additions and 0 deletions

34
.github/workflows/release.yml vendored Normal file
View file

@ -0,0 +1,34 @@
name: Release
on:
release:
types: [created]
jobs:
release-binaries:
name: Build release binaries
runs-on: ubuntu-18.04
steps:
- name: zfs libs
run: |
sudo apt-get install libzfs2linux libzfslinux-dev
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: build
args: --release
- name: Upload binary to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: target/release/palantir
asset_name: palantir
tag: ${{ github.ref }}

46
.github/workflows/rust.yml vendored Normal file
View file

@ -0,0 +1,46 @@
on: [push, pull_request]
name: CI
jobs:
check:
name: Check
runs-on: ubuntu-18.04
steps:
- name: zfs libs
run: |
sudo apt-get install libzfs2linux libzfslinux-dev
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: check
build:
name: Build
runs-on: ubuntu-18.04
steps:
- name: zfs libs
run: |
sudo apt-get install libzfs2linux libzfslinux-dev
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: build
args: --release
- uses: actions/upload-artifact@v2
with:
name: palantir
path: target/release/palantir