windjammer 0.48.0

A simple language inspired by Go, Ruby, and Elixir that transpiles to Rust - 80% of Rust's power with 20% of the complexity
Documentation
#!/bin/bash
# Windjammer pre-commit hook
# Runs formatter, linter, and tests before allowing a commit
#
# Install this hook by running: ./scripts/install-hooks.sh

set -e

echo "๐Ÿ” Running pre-commit checks..."
echo ""

# 1. Auto-format code and stage formatting changes
echo "๐Ÿ“ Running cargo fmt (auto-fix)..."
cargo fmt --all
# Stage any formatting changes so they're included in the commit
FORMATTED_FILES=$(git diff --name-only -- '*.rs')
if [ -n "$FORMATTED_FILES" ]; then
    echo "$FORMATTED_FILES" | xargs git add
    echo "โœ… Auto-formatted and staged changes"
else
    echo "โœ… Code already formatted"
fi
echo ""

# 2. Run linter
echo "๐Ÿ”Ž Running cargo clippy..."
if ! cargo clippy --all-targets --all-features -- -D warnings 2>&1 | grep -q "Finished"; then
    echo "โŒ Clippy check failed!"
    echo "   Fix linter warnings before committing."
    exit 1
fi
echo "โœ… Clippy check passed"
echo ""

# 3. Run tests
echo "๐Ÿงช Running cargo test..."
if ! cargo test --quiet 2>&1 | tail -5 | grep -q "test result: ok"; then
    echo "โŒ Tests failed!"
    echo "   Fix failing tests before committing."
    exit 1
fi
echo "โœ… All tests passed"
echo ""

echo "โœ… All pre-commit checks passed!"
echo "   Proceeding with commit..."
echo ""