Skip to content

readme: Fix bash commands on install instructions step #889

readme: Fix bash commands on install instructions step

readme: Fix bash commands on install instructions step #889

Workflow file for this run

name: Deploy unix
on: [push, pull_request]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-22.04
TARGET: x86_64-unknown-linux-gnu
SUFFIX: linux-desktop
- os: ubuntu-22.04
TARGET: armv7-unknown-linux-gnueabihf
SUFFIX: armv7
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.TARGET }}
override: true
profile: minimal
- name: Use cached dependencies
uses: Swatinem/rust-cache@v2
with:
key: "${{ matrix.os }}-${{ matrix.TARGET }}-${{ hashFiles('**/Cargo.lock') }}"
shared-key: "shared"
- name: Building for ${{ matrix.os }} ${{ matrix.target }} (${{ matrix.SUFFIX }})
uses: actions-rs/cargo@v1
with:
use-cross: true
command: build
args: --verbose --release --target ${{matrix.target}}
- name: Prepare files
run: |
mkdir -p upload
cp target/${{ matrix.TARGET }}/release/mavlink-camera-manager upload/mavlink-camera-manager-${{ matrix.SUFFIX }}
- uses: actions/upload-artifact@master
with:
name: mavlink-camera-manager-${{ matrix.SUFFIX }}
path: upload/*
- uses: svenstaro/upload-release-action@v2
name: Upload binaries to release
if: ${{ github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')}}
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: 'upload/mavlink-camera-manager-*'
asset_name: mavlink-camera-manager-${{ matrix.SUFFIX }}
tag: ${{ github.ref }}
overwrite: true
file_glob: true