Skip to content

Gacaca6/hanobusappdev

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

41 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

HanoBus

Real-time public transport tracking for Kigali.

Build License: MIT Platform Made in Rwanda

Live Demo Β· Report Bug Β· Request Feature


The Problem

Public transport in Kigali is a daily source of uncertainty. Commuters do not know when the next bus will arrive, which route to take, whether a bus is full, or if a delay or disruption is affecting their journey. Static schedules (where they exist) rarely match reality, and information is fragmented across operators, stops, and languages. The result is wasted time, missed appointments, and a transport system that feels chaotic even when the buses are running.

Our Solution

HanoBus brings real-time visibility to Kigali's public transport network. It shows live bus positions on a map, estimates arrival times for each stop, suggests the best route between any two points, and alerts users to delays or disruptions β€” all in Kinyarwanda, French, or English. Whether you're a student, a commuter, or a visitor, HanoBus turns the city's bus network into something you can actually plan around.

Features

  • πŸ—ΊοΈ Live GPS bus tracking β€” see every bus on the map, updated in real time
  • ⏱️ Real-time arrival estimates β€” know exactly when your bus will reach your stop
  • 🧭 Intelligent route planning β€” shortest, fastest, and least-crowded routes
  • 🌐 Multi-language β€” Kinyarwanda, French, and English
  • πŸ”” Push notifications β€” delays, detours, and service disruptions
  • ⭐ Favorites β€” save your frequent stops and routes
  • πŸ“΄ Offline-first β€” core features work without a connection

Tech Stack

Layer Technology Purpose
Frontend React 19 + TypeScript + Vite Fast, modern SPA with type safety
Styling Tailwind CSS v4 Utility-first, responsive UI
State Zustand Lightweight global state
Routing React Router v7 Client-side navigation
Maps Google Maps + Leaflet Live map rendering and bus overlays
Backend Firebase Serverless backend platform
Database Cloud Firestore Real-time sync of bus positions and routes
Auth Firebase Auth Email/password + Google Sign-In
Functions Firebase Cloud Functions Server-side logic and scheduled jobs
Notifications Firebase Cloud Messaging (FCM) Push notifications for delays and alerts
PWA vite-plugin-pwa + Workbox Installable, offline-capable web app
AI Google GenAI (Gemini) Smart assistance and natural-language search

Getting Started

Prerequisites

  • Node.js 20 or newer
  • npm 10 or newer
  • A Firebase project (Firestore, Auth, FCM enabled)
  • A Google Maps API key

Installation

# 1. Clone the repo
git clone https://github.com/<your-org>/hanobus.git
cd hanobus

# 2. Install dependencies
npm install

# 3. Configure environment variables
cp .env.example .env.local
# then fill in your Firebase + Google Maps keys in .env.local

# 4. Start the dev server
npm run dev

The app will be available at http://localhost:3000.

Available Scripts

Script Description
npm run dev Start the Vite dev server
npm run build Build the production bundle
npm run preview Preview the production build locally
npm run lint Type-check the project with tsc
npm run format Format the codebase with Prettier

Project Structure

hanobus/
β”œβ”€β”€ public/                  # Static assets (icons, banner, manifest)
β”œβ”€β”€ scripts/                 # Build / seeding scripts
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ components/          # Reusable UI components
β”‚   β”‚   β”œβ”€β”€ BottomNav.tsx
β”‚   β”‚   β”œβ”€β”€ Map.tsx
β”‚   β”‚   β”œβ”€β”€ Onboarding.tsx
β”‚   β”‚   └── ...
β”‚   β”œβ”€β”€ pages/               # Route-level screens
β”‚   β”‚   β”œβ”€β”€ Home.tsx
β”‚   β”‚   β”œβ”€β”€ RoutesPage.tsx
β”‚   β”‚   β”œβ”€β”€ AlertsPage.tsx
β”‚   β”‚   └── ...
β”‚   β”œβ”€β”€ data/                # Static route/stop data
β”‚   β”œβ”€β”€ i18n/                # Kinyarwanda / French / English strings
β”‚   β”œβ”€β”€ services/            # Firebase + API services
β”‚   β”œβ”€β”€ store/               # Zustand stores
β”‚   β”œβ”€β”€ utils/               # Helpers
β”‚   β”œβ”€β”€ firebase.ts          # Firebase initialization
β”‚   β”œβ”€β”€ App.tsx              # App shell
β”‚   └── main.tsx             # Entry point
β”œβ”€β”€ firestore.rules          # Firestore security rules
β”œβ”€β”€ vite.config.ts
└── package.json

Screenshots

Home Live Map Route Detail
Home Map Route

Live Demo

🌍 hanobus.vercel.app

πŸ“š Documentation

Document Description
Project Overview One-page summary of HanoBus for judges and new visitors
Architecture System design and data flow
API Reference Cloud Functions documentation
Database Schema Firestore collections and structure
Setup Guide Detailed developer setup
Deployment How to deploy to production
Testing Testing strategy and checklist
Security Policy Data handling and vulnerability reporting

Contributing

Contributions are welcome! Please read CONTRIBUTING.md before opening a pull request.

License

This project is licensed under the MIT License β€” see the LICENSE file for details.


Built for the Tech Builder Program Hackathon 2026 πŸ‡·πŸ‡Ό

Made with ❀️ in Kigali, Rwanda.

About

Real-time bus tracking for commuters in Kigali

Topics

Resources

License

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages