Overview
The--status (or -s) flag provides a single-line output showing the next upcoming prayer event with a countdown. This mode is perfect for status bars, coding agents, and minimal displays.
Basic Usage
Status mode is completely non-interactive and silent on failure. Itβs designed to never interrupt your workflow.
Output Format
The status line shows the next prayer event with time remaining:Possible Event Labels
- Regular Events
- Edge Cases
Countdown Format
Hours and Minutes
Minutes Only
Final Minutes
Status Bar Integration
tmux
Add Ramadan timings to your tmux status bar:Polybar
Integrate with Polybar status bar:i3status
Add to i3status configuration:Waybar
For Wayland users with Waybar:Terminal Integration
Shell Prompt (PS1)
Add to your shell prompt:Coding Agent Integration
VS Code Status Bar
Create a VS Code extension:JetBrains IDEs
For IntelliJ, PyCharm, WebStorm, etc.:Neovim/Vim Statusline
Location Override
Use--city to query a different location in status mode:
Error Handling
Silent Failure Behavior
Status mode fails silently by design:This prevents error messages from cluttering your status bar.
Fallback Display
Provide a fallback for when status mode fails:Performance Optimization
Caching Strategy
Since countdowns change every minute, cache for 60 seconds:Background Updates
Use a background process to keep the cache warm:Complete Examples
Minimal tmux Setup
Polybar with Tooltip
Shell Script Widget
Testing
1
Test Basic Output
2
Test with Location
3
Test Error Handling
4
Test in Status Bar
Add to your status bar config and reload:
Troubleshooting
No output appears
No output appears
- Check if ramadan-cli is installed:
which ramadan-cli - Test manually:
ramadan-cli -s - Check exit code:
ramadan-cli -s; echo $? - Verify PATH in status bar environment
Output is too long
Output is too long
The status line is designed to be concise. Maximum length is around 20-30 characters:If truncated, adjust your status bar width settings.
Status doesn't update
Status doesn't update
- Check refresh interval in your status bar config
- Verify the CLI is being called each time
- Try clearing any caches:
rm /tmp/ramadan-*
Wrong timezone displayed
Wrong timezone displayed
Configure timezone explicitly:Then test:
Best Practices
Cache Aggressively
Update every 60 seconds, not on every display refresh
Handle Failures
Always provide a fallback display value
Suppress Errors
Redirect stderr to /dev/null in status bars
Keep It Simple
Status line is for quick glances, not detailed info
See Also
JSON Output
Structured output for advanced integrations
Agent Usage
Using ramadan-cli in automated workflows