You can not select more than 25 topics
Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- #!/bin/bash
- set -euo
-
- # List of ignored modules
- ignored_folders=("dora-internvl" "dora-parler" "dora-keyboard" "dora-microphone" "terminal-input")
-
- # Get current working directory
- dir=$(pwd)
-
- # Get the base name of the directory (without the path)
- base_dir=$(basename "$dir")
-
- # Check if the directory name is in the ignored list
- if [[ " ${ignored_folders[@]} " =~ " ${base_dir} " ]]; then
- echo "Skipping $base_dir as we cannot test it on the CI..."
- else
- if [ -f "$dir/Cargo.toml" ]; then
- echo "Running build and tests for Rust project in $dir..."
- cargo check
- cargo clippy
- cargo build
- cargo test
-
- # aarch64-unknown-linux-gnu
- rustup target add aarch64-unknown-linux-gnu
- cargo check --target aarch64-unknown-linux-gnu
-
- # armv7-unknown-linux-musleabihf
- rustup target add armv7-unknown-linux-musleabihf
- cargo check --target armv7-unknown-linux-musleabihf
- else
- if [ -f "$dir/pyproject.toml" ]; then
- echo "Running linting and tests for Python project in $dir..."
- pip install .
- poetry run black --check .
- poetry run pylint --disable=C,R --ignored-modules=cv2 **/*.py
- poetry run pytest
- fi
- fi
- fi
|