evgene-kopylov_fsrs_plugin/scripts/check.sh

38 lines
664 B
Bash
Executable file
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/bin/sh
# Локальный прогон всех проверок перед коммитом.
# Заменяет CI-джобы: cargo fmt, clippy, test, npm test, tsc, eslint, build.
# Запуск: sh scripts/check.sh
set -e
echo "=== 1. cargo fmt ==="
cd wasm-lib
cargo fmt -- --check
cd ..
echo ""
echo "=== 2. cargo clippy ==="
cd wasm-lib
cargo clippy -- -D warnings
cd ..
echo ""
echo "=== 3. cargo test ==="
cd wasm-lib
cargo test
cd ..
echo ""
echo "=== 4. npm run build ==="
npm run build
echo ""
echo "=== 5. npm run lint ==="
npm run lint
echo ""
echo "=== 6. npm test ==="
npm test
echo ""
echo "Все проверки пройдены."