Skip to main content

Terminal-based timetable viewer for Gautam Buddha University

Project description

📅 GBU Timetable CLI

A terminal-based interactive timetable viewer for Gautam Buddha University, built with Python and Rich. Browse departments, select sections, save preferences, and view G1/G2 lab splits cleanly inside your terminal.


✨ Features

  • 🎯 Interactive keyboard-driven CLI
  • 🏫 Browse by School → Department → Code → Section
  • 💾 Save default section (auto-load on next run)
  • 🧪 Smart G1 / G2 lab stacking in the same period
  • ⏰ Automatic 12-hour AM/PM time slots
  • 🎨 Clean, readable UI using rich
  • ⚡ Zero configuration after first setup

📦 Installation

pip install gbu-timetable

Requires Python 3.8+


🚀 Usage

Run directly from terminal:

timetable

No flags, no arguments — fully interactive.


🧭 Navigation Controls

Key Action
1 View saved timetable
2 Browse & select section
3 Enter section ID directly
b Go back
m Return to main menu
q Quit

🗂️ Saved Configuration

Your selected section is stored locally at:

~/.timetable_cli.json

Example:

{
  "section_id": "1278",
  "section_name": "B.Tech CSE (A)"
}

This allows instant access next time using “View Saved Timetable”.


🧪 G1 / G2 Lab Handling

When multiple entries exist in the same period:

  • G1 and G2 are automatically detected
  • Displayed as stacked panels inside the same cell
  • Color-coded for quick differentiation

No manual filtering required.


🕒 Time Slot Logic

  • Default start time: 08:30 AM
  • Each period: 60 minutes
  • Automatically adapts to timetable length
  • Displayed in 12-hour format

Example:

P3
10:30 AM – 11:30 AM

🌐 Data Source

Timetable data is fetched from:

https://samay.mygbu.in/api.php

Data is fetched once per run for performance and simplicity.


🧱 Project Structure

gbu-timetable/
│
├── timetable/
│   ├── __init__.py
│   └── cli.py
│
├── pyproject.toml
├── README.md
└── LICENSE

🛠️ Development Setup

git clone https://github.com/shashaaankkkkk/gbu-timetable
cd gbu-timetable
pip install -e .

Run locally:

timetable

📚 Dependencies

  • requests
  • readchar
  • rich

Installed automatically via pip.


👨‍💻 Author

Shashank Shekhar Full Stack Developer & CLI Tool Builder

🔗 GitHub: https://github.com/shashaaankkkkk/


📄 License

MIT License — free to use, modify, and distribute.


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gbu_timetable-0.1.2.tar.gz (5.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gbu_timetable-0.1.2-py3-none-any.whl (5.9 kB view details)

Uploaded Python 3

File details

Details for the file gbu_timetable-0.1.2.tar.gz.

File metadata

  • Download URL: gbu_timetable-0.1.2.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for gbu_timetable-0.1.2.tar.gz
Algorithm Hash digest
SHA256 c911835a7fae86edaae797d3aba72d9b1354cb537de2144f1704bb7dd3623627
MD5 68e05956f1f1af7d751f41610d48ca37
BLAKE2b-256 ad689440ab45a6d80235244f5ee7681cb48aa508db9af97445fe88c3f70d378d

See more details on using hashes here.

File details

Details for the file gbu_timetable-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: gbu_timetable-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 5.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for gbu_timetable-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 dcc53eb43b723f8122e54c90410f18f63b2981d2732659d8bbc925583c0cbc9e
MD5 e9002cf704f52bc8d8f8381ea8d03ebb
BLAKE2b-256 81ba648ab7e1cd939a59aafc636b3fb2e92e6ad45f503b3cd662591ba9cf30a4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page