-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Summary
Integrate himalaya CLI email client into flow-cli with ADHD-friendly shell wrappers, fzf-powered email browsing, smart rendering, and desktop notifications.
Architecture: himalaya → email-oauth2-proxy (localhost) → Office 365 (OAuth2)
Proposed Features
1. Core Email Aliases
| Alias | Command | Purpose |
|---|---|---|
hm |
himalaya |
Base command |
hml |
himalaya envelope list |
List inbox |
hmr |
himalaya message read |
Read message |
hmw |
himalaya message write |
Compose |
hmf |
himalaya folder list |
List folders |
hms |
himalaya envelope list -f 'Sent Items' |
Sent mail |
2. Shell Functions
hminbox [N]— Quick inbox check (default 25)hmunread— Unread counthmread <ID>— Read with bat syntax highlighting + paginghmhtml <ID>— Render HTML email via w3mhmpick [FOLDER]— fzf interactive email picker with previewhmreply <ID>— Quick replyhmattach <ID>— Download attachmentshmfind <query>— Search and browsehmdash— Dashboard (unread count + latest 10)
3. fzf Integration
- Email picker with preview pane (
hmpick) - Folder browser (
hfolder) - Search with fzf preview (
hsearch) - JSON-powered rich display mode (
hpick_json)
4. Smart Rendering Pipeline
- Auto-detect HTML vs plaintext content
- HTML → w3m rendering
- Markdown → glow rendering
- Fallback → bat syntax highlighting
- Combined in
hpage()smart pager function
5. Notification Integration
himalaya envelope watchwith built-in IMAP IDLE hooksterminal-notifierpoll-based fallback (LaunchAgent)- Optional: Mirador (Pimalaya ecosystem watcher)
6. Config Display Enhancements
- Color theme (Tokyo Night inspired): cyan subjects, blue senders, magenta flags
- UTF8 table preset for box-drawing characters
- Friendlier datetime format (
%b %d %H:%M) - Custom flag characters (
+unread,!flagged,@attachment)
Dependencies
| Tool | Install | Required? |
|---|---|---|
| himalaya | cargo install himalaya |
Yes |
| w3m | brew install w3m |
Recommended (HTML rendering) |
| bat | brew install bat |
Recommended (paging) |
| glow | brew install glow |
Optional (Markdown rendering) |
| fzf | brew install fzf |
Recommended (interactive picker) |
| jq | brew install jq |
Recommended (JSON processing) |
| terminal-notifier | brew install terminal-notifier |
Optional (notifications) |
| urlscan | brew install urlscan |
Optional (URL extraction) |
Implementation Plan
Quick Wins
- Add core aliases to
zsh/aliases/ - Add color/display config to himalaya
config.toml - Install w3m + bat
Medium Effort
- Build fzf email picker functions in
zsh/functions/ - Set up
envelope watchwith notification hooks - Create smart rendering pipeline (
hpage)
Long-term
- Neverest + Notmuch for offline full-text search
- LaunchAgent for poll-based notifications
- Integration with
dashcommand (email section in master dashboard) - Integration with
workcommand (email context per project)
Full Research Document
Complete research with code examples, config references, community discussion, and tool comparisons:
Covers: plugin ecosystem, HTML rendering, pager integration, fzf integration, Notmuch backend, MML/MIME handling, wrapper scripts, config display options, TUI frontends, email notifications, neomutt/aerc comparison, and community discussions.
Context
- Email setup: UNM LoboMail (Microsoft 365) via email-oauth2-proxy (device code flow)
- Proxy runs as launchd service (
com.emailproxy) - Config:
~/.config/himalaya/config.toml - Tutorial:
~/.config/himalaya/TUTORIAL.md
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request