Skip to content

readme

readme #145

Workflow file for this run

name: build
on:
pull_request:
push:
branches:
- main
release:
types:
- published
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
strategy:
matrix:
runs-on:
- "ubuntu-latest"
- "macos-latest"
- "windows-latest"
fail-fast: false
runs-on: ${{ matrix.runs-on }}
steps:
- if: runner.os == 'Linux'
run: sudo apt install -y pkg-config libusb-1.0-0-dev libftdi1-dev libudev-dev
- uses: actions/checkout@v3
- uses: actions-rust-lang/setup-rust-toolchain@v1
- run: cargo build --release
- if: runner.os == 'Linux' || runner.os == 'macOS'
run: chmod +x target/release/packetraven
- uses: vimtor/action-zip@v1.1
with:
files: target/release/packetraven${{ runner.os == 'Windows' && '.exe' || '' }}
dest: ${{ runner.os }}.zip
- uses: actions/upload-artifact@v3
with:
name: ${{ runner.os }}
path: target/release/packetraven${{ runner.os == 'Windows' && '.exe' || '' }}
- if: (github.event_name == 'release' && github.event.action == 'published')
uses: svenstaro/upload-release-action@v2
with:
file: ${{ runner.os }}.zip