Merge InvArch into main and restructure workspace #365
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: Checks | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
paths: | |
- '.github/workflows/build.yml' | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
name: Build | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Get changed files | |
id: changed-files | |
uses: tj-actions/changed-files@v40 | |
with: | |
fetch_depth: 0 | |
dir_names: true | |
dir_names_max_depth: 1 | |
- name: Setup for checks | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'tinkernet') || contains(steps.changed-files.outputs.all_modified_files, 'invarch') | |
run: sudo apt install -y git clang curl libssl-dev llvm libudev-dev protobuf-compiler | |
- name: Build [tinkernet] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'tinkernet') | |
working-directory: ./tinkernet | |
run: cargo build --verbose | |
- name: Run tests [tinkernet] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'tinkernet') | |
working-directory: ./tinkernet | |
run: cargo test --verbose | |
- name: Run clippy [tinkernet] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'tinkernet') | |
working-directory: ./tinkernet | |
run: cargo clippy -- -D warnings | |
- name: Run cargofmt [tinkernet] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'tinkernet') | |
working-directory: ./tinkernet | |
run: cargo +stable fmt --all -- --check | |
- name: Build [invarch] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'invarch') | |
working-directory: ./invarch | |
run: cargo build --verbose | |
- name: Run tests [invarch] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'invarch') | |
working-directory: ./invarch | |
run: cargo test --verbose | |
- name: Run clippy [invarch] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'invarch') | |
working-directory: ./invarch | |
run: cargo clippy -- -D warnings | |
- name: Run cargofmt [invarch] | |
if: | |
contains(steps.changed-files.outputs.all_modified_files, 'invarch') | |
working-directory: ./invarch | |
run: cargo +stable fmt --all -- --check |