Skip to content

SyedEshaan-ctrl/Bus-Locator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 

Repository files navigation

🚍 College Bus Location Sharing System

A fully responsive, full-stack real-time location sharing app for college bus tracking. Built with modern tools and optimized for AI development with Cursor.


🧠 Overview

Students can:

  • Log in securely
  • Share their live location
  • View real-time locations of buses and students on a map

Built using:

  • Next.js + Tailwind CSS
  • Supabase (Auth + DB + Realtime)
  • Leaflet.js for mapping
  • Vercel for deployment
  • Cursor IDE for AI-assisted development

✨ Features

βœ… Authentication

  • Supabase Email Auth
  • Sign Up captures: Name, Roll Number, Email, Bus Number, Start Point
  • Session management and access control

πŸ“ Location Sharing

  • β€œShare My Location” button
  • Live GPS tracking via browser geolocation API
  • Location stored in Supabase locations table
  • Tracks timestamp, lat, long per user

πŸ—ΊοΈ Dashboard Map

  • Leaflet-based map showing:
    • All student locations
    • Calculated average/most recent position for each bus
  • Realtime auto-updates via Supabase subscriptions

πŸ” Filters & Search

  • Filter by:
    • Bus Number
    • Starting Point
  • Search by:
    • Roll Number
    • Student Name

🧱 Database Schema

users table

Column Type Description
id UUID PK, from Supabase
name TEXT Student Name
email TEXT Unique, for login
roll_number TEXT Unique Student ID
bus_number TEXT Assigned Bus
start_point TEXT Starting Location

locations table

Column Type Description
id UUID PK
user_id UUID FK to users
latitude FLOAT Current Latitude
longitude FLOAT Current Longitude
timestamp TIMESTAMP Time of location capture

🧰 Tech Stack

Layer Technology
Frontend Next.js (App Router)
Styling Tailwind CSS
Backend Supabase
Realtime Supabase Subscriptions
Maps Leaflet.js
Deployment Vercel
Development Cursor IDE

πŸš€ Deployment

  1. Clone the repo
git clone https://github.com/your-username/bus-tracker
cd bus-tracker

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors