Skip to main content

Amazing terminal analog clock with rainbow gradients and dynamic effects

Project description

🌈 Rainbow Analog Clock

An amazing terminal-based analog clock with dynamic visual effects, rainbow gradients, and smooth animations.

Python Version License PyPI

✨ Features

Beautiful Analog Clock

  • Perfect circular design with aspect ratio compensation
  • Rainbow gradient border with continuous color rotation
  • Numbered hour markers (1-12) with special markers at 3, 6, 9, 12
  • Three distinct hands: hour (red), minute (green), second (cyan)
  • Glowing effects on hands and markers
  • Pulsing current hour indicator

🎆 7 Dynamic Visual Effects

  1. Classic - Clean clock without particle effects
  2. Fireworks - Random colorful firework bursts
  3. Rain - Continuous rainbow raindrops
  4. Stars - Twinkling stars across the screen
  5. Matrix - Matrix-style falling characters
  6. Sparkle - Sparkles orbiting the clock face
  7. Snow - Gentle falling snowflakes

🎮 Interactive Controls

  • SPACE - Cycle through effects
  • R - Toggle random mode (auto-switches every 10 seconds)
  • Ctrl+C - Exit gracefully

Performance

  • Smooth 20 FPS animation
  • No flickering with proper double-buffering
  • Efficient particle system with automatic cleanup

Requirements

  • Python 3.10+
  • A terminal with true color (RGB) support
  • Unix-like system (Linux, macOS)

🚀 Quick Start

Run with uvx (recommended):

No installation needed! Run directly:

uvx rainbow-clock

Install with uv:

uv tool install rainbow-clock
rainbow-clock

Install with pip:

pip install rainbow-clock
rainbow-clock

Run from source:

git clone https://github.com/derluke/rainbow-clock.git
cd rainbow-clock
python3 -m rainbow_clock

📦 Project Structure

  • rainbow_clock/ - Main package directory
    • __init__.py - Clock application with particle effects
  • analog_clock.py - Basic clock version without effects
  • pyproject.toml - Project configuration
  • README.md - This file
  • LICENSE - MIT License

How It Works

The clock uses:

  • Bresenham's line algorithm for smooth clock hands
  • Midpoint circle/ellipse algorithm for the clock face
  • Custom particle system with physics simulation
  • ANSI escape codes for RGB colors and cursor positioning
  • Aspect ratio compensation for perfect circles in terminal
  • Non-blocking input for interactive controls

Enjoy your colorful time! ⏰✨

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

rainbow_clock-0.1.0.tar.gz (9.7 kB view details)

Uploaded Source

Built Distribution

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

rainbow_clock-0.1.0-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file rainbow_clock-0.1.0.tar.gz.

File metadata

  • Download URL: rainbow_clock-0.1.0.tar.gz
  • Upload date:
  • Size: 9.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.8

File hashes

Hashes for rainbow_clock-0.1.0.tar.gz
Algorithm Hash digest
SHA256 a02337cf15536a5cde47633089e5921b8605b0e972ff23b77b1e26c8783a73d4
MD5 7b79e34e9453ffe8cf459854672dc27f
BLAKE2b-256 d65f36fe36b73162ba9996ac62e3ea2bc485acb7f2ee4416fa029d88178c65a6

See more details on using hashes here.

File details

Details for the file rainbow_clock-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for rainbow_clock-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 88ddb7bdd1ab7ed82886137b30d5660d95639b7a2a5be0102204046fe0f751b6
MD5 6162ec0882465d033b640eddd42bbf89
BLAKE2b-256 6246c5f3f46ae59f69db48ee9be4a47d0771fc055e17b0ff2a956ca8cc6ed745

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