30 lines
1.1 KiB
Bash
Executable File
30 lines
1.1 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# Run on a clean Rust 1.99+ build machine with registry and Swagger asset access.
|
|
set -euo pipefail
|
|
ROOT="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")/.." && pwd)"
|
|
cd "$ROOT"
|
|
if ! command -v cargo >/dev/null 2>&1 || ! command -v rustc >/dev/null 2>&1; then
|
|
printf 'Rust 1.99+ and Cargo are required; no lockfile was regenerated.\n' >&2
|
|
exit 127
|
|
fi
|
|
python3 tools/checks/preflight.py
|
|
if [[ "$(python3 scripts/version.py)" != '0.31.6' ]]; then
|
|
printf 'Expected RustProxy 0.31.6 sources.\n' >&2
|
|
exit 1
|
|
fi
|
|
printf 'Toolchain: '; rustc --version
|
|
cargo update
|
|
python3 tools/checks/dependency_upgrade_0312.py --require-lock
|
|
cargo metadata --locked --format-version 1 --no-deps >/dev/null
|
|
cargo fmt --all -- --check
|
|
cargo clippy --locked --all-targets -- -D warnings
|
|
./dev.sh check
|
|
./dev.sh test
|
|
./dev.sh release
|
|
if cargo audit --version >/dev/null 2>&1; then
|
|
cargo audit
|
|
else
|
|
printf 'NOTICE: cargo-audit is unavailable; install it and run cargo audit before release.\n' >&2
|
|
fi
|
|
printf 'Source and locked Rust build complete. Still required: live H1/H2/H3, auth/TLS, SQLite, cache, UI and performance acceptance.\n'
|