bevy/tools/ci
Nathan Stocks 940bcf9b0f
Add Contributing Info (#1309)
* Add a CONTRIBUTING.md

* Point to book. Add tools/ci script.

* Update contributing link to point to book
2021-01-26 12:05:33 -08:00

20 lines
No EOL
723 B
Bash
Executable file

#!/usr/bin/env bash
# This script is intended to mimic some CI behavior that we encourage contributors to run locally.
# For the actual CI run on GitHub, see the files in .github/workflows/
# Exit when any command fails
set -e
# Keep track of the last executed command
trap 'last_command=$current_command; current_command=$BASH_COMMAND' DEBUG
# Echo an error message before exiting, so you can see exactly what command and what error code
trap 'echo "\"${last_command}\" command filed with exit code $?."' EXIT
## ACTUAL COMMANDS
# Auto-format Rust files
cargo +nightly fmt --all
# Run a more intensive linter
cargo clippy --all-targets --all-features -- -D warnings -A clippy::type_complexity -A clippy::manual-strip