A lightweight, premium native macOS status bar application that monitors critical market breadth and institutional sentiment indicators. It displays a real-time summary directly in your status menu bar, which opens a high-fidelity visual dashboard panel upon clicking.
Built entirely in native Swift, Cocoa, and SwiftUI with zero external dependencies, compiling into an extremely optimized, standalone executable that runs in accessory mode (hidden from the Dock) and consumes near-zero system resources.
- 📈 Dynamic Status Bar Summary: Displays live advancing percentage and active bullish sentiment directly in your menu bar (e.g.
📊 55.5% 🐂 65%). Clicking the status bar indicator toggles the visual dashboard. - 🎨 Premium 5-Card Vertical Layout: Renders five highly detailed vertical cards (
width: 200,height: 280) side-by-side in a sleek slate charcoal theme:- **
ADV/DECL RATIO:**NYSE/Nasdaq/AMEX advancing vs. declining stocks percentage, organic sparkline, and segmented bar. NET NEW HIGHS: Stocks hitting 52-week highs vs. 52-week lows.% ABV 50-DAY MA: Percentage of stocks trading above their 50-day Simple Moving Average.VIX INDEX: CBOE Volatility Index, charting real-time fear/risk-appetite indices.EQUITY PUT/CALL: CBOE Equity Options Put/Call ratio, charting active hedging volumes.
- **
- 📌 Detachable Glassmorphic HUD Window: Tapping
Keep Floatingin the footer detaches the dashboard from the status bar into a borderless floating utility window (NSPanel) with a native macOS glassmorphic blur backdrop (NSVisualEffectView) that stays on top of other workspace windows. - 📊 Institutional Sparklines & Grids: Sparklines are color-coded (green for bullish/risk-on, red for bearish/risk-off) and feature three horizontal grid lines, left-aligned custom Y-axis tick scales, time markers (
0:00and13:30), and custom dotted baseline thresholds. - 📷 Clipboard-Only Screenshots: Captures the entire dashboard, copies it instantly to the macOS clipboard, triggers a green success toast indicator, and issues a standard system chime (no cluttering local disk files).
- 🌙 NYSE Hours Integration & Sleeping Indicator: Detects whether the NY Stock Exchange is active. Skips background fetches outside market hours to save network calls, displaying an amber sleeping moon (
moon.zzz.fill) paused label. - 🎛️ Dynamic scaling: Top header font controls dynamically scale all dashboard components (sparklines, tick labels, buttons, progress bars) between
80%and140%smoothly, persisting your choice via@AppStorage. - ⚡ Ultra-Light Footprint: Performs parallel network queries using Combine's
Zip4publisher pipeline (fetching HTML and JSON data in parallel in under 100ms). Operates at 0.0% CPU in the background, consuming less than 48 MB of RAM.
The application is completely self-contained in five core files:
- Parser.swift: Core models (
MarketBreadthItem,MarketIndexData,MarketSentimentData) and the network fetching engine (MarketBreadthFetcher) executing parallel URLSession pipelines. - BreadthViews.swift: High-fidelity SwiftUI visual modules, sparklines, segmented bars, range indicators, and layout controllers.
- AppDelegate.swift: Core status item lifecycle, NSPopover controls, AppKit
NSPanelfloating window controller, and screenshot copying procedures. - main.swift: Accessories mode entry hook initializing the AppKit environment loop.
- build.sh: Programmatic compilation script invoking Apple's native Swift compiler (
swiftc) linked to Cocoa system libraries.
To compile the standalone binary on any modern macOS machine:
- Open your Terminal and navigate to the project directory:
cd /Users/vikasbhatia/code/marketwatch - Execute the compilation script:
./build.sh
./MarketWatch &./MarketWatch -i 120 &(Programmatically enforces a minimum safety threshold of 10 seconds to protect against rate-limiting).
To register the app so that it starts automatically in the background whenever your Mac boots up or you log in:
chmod +x install_launch_agent.sh
./install_launch_agent.sh(This sets up a plist Launch Agent under ~/Library/LaunchAgents/com.marketwatch.plist that supervises, automatically restarts, and runs the application background loops).
- Status Bar: Look at the top-right of your screen for the dynamic indicator (e.g.
📊 55.5% 🐂 65%). Click it to open the dashboard. - Detached Mode: Click the
pin.fillKeep Floating button in the footer to pop the dashboard out into a floating glass panel. Move it anywhere on your desktop. Click it again to snap it back. - Visual Spring Scale: Hovering over any card tile expands it (+2% scale) and intensifies the dynamic glassmorphic radial background glow (green for bullish, red for bearish).
- Screenshot Sharing: Click the
📷 Screenshotbutton in the footer to copy the dashboard directly to your clipboard for instant pasting into Slack, iMessage, or mail applications. - Quit: Click the
Quit Appbutton in the footer (visible in Popover mode) or click the close traffic light on the HUD Panel to exit the application cleanly.