Development Setup
Prerequisites
Quick Start
# Clone the repository
git clone https://github.com/ltoinel/Glove.git
cd Glove
# Download GTFS data
bin/download.sh gtfs
# Start in dev mode (auto-reload on file changes)
bin/start.sh --dev
Backend Development
cargo build # Debug build
cargo build --release # Release build
cargo test # Run all tests
cargo clippy -- -D warnings # Lint (must pass in CI)
cargo fmt --check # Format check (must pass in CI)
cargo fmt # Auto-format
The dev mode uses cargo-watch to recompile automatically on file changes:
cargo install cargo-watch
cargo watch -x run
Frontend Development
cd portal
npm install # Install dependencies
npm run dev # Vite dev server on port 3000 with HMR
npm run build # Production build to dist/
npx eslint src/ # Lint (must pass in CI)
CI Pipeline
GitHub Actions runs on every push to master and on pull requests:
- Backend: format check, clippy, build, test
- Coverage: cargo-tarpaulin with Codecov upload
- Frontend: ESLint + Vite build
All checks must pass before merging.
Useful Commands
# Run with debug logging
RUST_LOG=debug cargo run
# Run benchmarks
python3 bin/benchmark.py --rounds 10
# Start Valhalla for walk/bike/car routing
bin/valhalla.sh
# Check which GTFS transfer pairs have indoor routing data in Valhalla
python3 bin/check_indoor.py