npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@naarang/glancebar

v1.0.9

Published

A customizable statusline for Claude Code - display calendar events, tasks, and more at a glance

Readme

@naarang/glancebar

npm version license

A customizable statusline for Claude Code - display calendar events, tasks, and more at a glance.

Features

  • Session info - Project name, git branch, model, cost, lines changed, and context usage
  • System stats - CPU and memory usage (optional)
  • Calendar events - Upcoming events from Google Calendar and Zoho Calendar
  • Zoho Tasks - Display top pending tasks from Zoho Mail
  • Meeting warnings - Red alert when a meeting is 5 minutes away
  • Health reminders - Water, stretch, and eye break reminders
  • Color-coded - Everything has distinct colors for quick scanning
  • Fully configurable via CLI
  • Cross-platform support (Windows, macOS, Linux)

Requirements

  • Bun >= 1.0.0
  • Google Cloud project with Calendar API enabled (for Google Calendar)
  • Zoho API Console credentials (for Zoho Calendar)

Installation

Using bunx (recommended)

bunx @naarang/glancebar --help

Global installation

bun install -g @naarang/glancebar

Using npm

npx @naarang/glancebar --help
# or
npm install -g @naarang/glancebar

Quick Start

# 1. Run setup guide
glancebar setup

# 2. Add your account (after setting up credentials)
glancebar auth --add [email protected]
# Select Google (1) or Zoho (2) when prompted

# 3. Test it
glancebar

Setup

Google Calendar Setup

1. Create Google Cloud Project

  1. Go to Google Cloud Console
  2. Create a new project or select an existing one
  3. Enable the Google Calendar API:
    • Go to "APIs & Services" > "Library"
    • Search for "Google Calendar API" and enable it

2. Create OAuth Credentials

  1. Go to "APIs & Services" > "Credentials"
  2. Click "Create Credentials" > "OAuth client ID"
  3. Select "Desktop app" as application type
  4. Give it a name and click "Create"
  5. Download the JSON file
  6. Rename to credentials.json and save to ~/.glancebar/credentials.json

3. Add Redirect URI

Desktop app credentials don't show a redirect URI field in the console UI. You need to manually edit the downloaded credentials.json file:

  1. Open ~/.glancebar/credentials.json in a text editor
  2. Find the "redirect_uris" array and ensure it contains:
    "redirect_uris": ["http://localhost:3000/callback"]
  3. Save the file

Alternatively, you can add it via Google Cloud Console:

  1. Go to "APIs & Services" > "Credentials"
  2. Click on your OAuth client to edit it
  3. Under "Authorized redirect URIs", click "Add URI"
  4. Enter http://localhost:3000/callback
  5. Save and re-download the JSON file

Zoho Calendar Setup

1. Register Application

  1. Go to Zoho API Console
  2. Click "Add Client" > "Server-based Applications"
  3. Enter application details

2. Configure Client

  1. Set Authorized Redirect URI: http://localhost:3000/callback
  2. Note your Client ID and Client Secret

3. Save Credentials

Create ~/.glancebar/zoho_credentials.json:

{
  "client_id": "YOUR_CLIENT_ID",
  "client_secret": "YOUR_CLIENT_SECRET"
}

Add Accounts

# Add Google Calendar account
glancebar auth --add [email protected]
# Select "1" for Google Calendar

# Add Zoho Calendar account
glancebar auth --add [email protected]
# Select "2" for Zoho Calendar
# Then select your datacenter region (1-7)

Zoho Datacenters: | Choice | Region | Domain | |--------|--------|--------| | 1 | United States | zoho.com | | 2 | Europe | zoho.eu | | 3 | India | zoho.in | | 4 | Australia | zoho.com.au | | 5 | China | zoho.com.cn | | 6 | Japan | zoho.jp | | 7 | Canada | zohocloud.ca |

Configure Claude Code

Update ~/.claude/settings.json:

{
  "statusLine": {
    "type": "command",
    "command": "bunx @naarang/glancebar",
    "padding": 0
  }
}

Usage

Statusline Output

glancebar
# Output: In 15m: Team Standup (work)

Commands

| Command | Description | |---------|-------------| | glancebar | Display statusline output | | glancebar auth | Re-authenticate all accounts | | glancebar auth --add <email> | Add a new account | | glancebar auth --remove <email> | Remove an account | | glancebar auth --list | List all accounts | | glancebar config | Show current configuration | | glancebar setup | Show setup instructions | | glancebar --help | Show help |

Configuration Options

# Set lookahead hours (how far ahead to look for events)
glancebar config --lookahead 12

# Set countdown threshold (show "In Xm" instead of time)
glancebar config --countdown-threshold 30

# Set max title length
glancebar config --max-title 80

# Toggle calendar name display
glancebar config --show-calendar false

# Enable/disable health reminders
glancebar config --water-reminder true
glancebar config --stretch-reminder true
glancebar config --eye-reminder true

# Enable/disable system stats
glancebar config --cpu-usage true
glancebar config --memory-usage true

# Enable/disable Zoho tasks display
glancebar config --zoho-tasks true
glancebar config --max-tasks 3

# Reset to defaults
glancebar config --reset

Display Format

Example output:

glancebar | main* | Opus | $0.12 | +156 -23 | 9.7k/200k (5%) | In 15m: Team Standup (work)

Session Info (from Claude Code)

| Field | Color | Example | |-------|-------|---------| | Project name | Blue | glancebar, my-app | | Git branch | Magenta | main, feature-x* (asterisk = uncommitted changes) | | Model name | Yellow | Opus, Sonnet | | Cost | Green | $0.01, $0.1234 | | Lines changed | Green/Red | +156 -23 | | Context usage | Green/Yellow/Red | 9.7k/200k (5%) | | CPU usage | Green/Yellow/Red | CPU 12% | | Memory usage | Green/Yellow/Red | Mem 8.2/16.0GB |

Context usage color changes based on percentage:

  • Green: < 50%
  • Yellow: 50-80%
  • Red: > 80%

Calendar Events

| State | Format | Example | |-------|--------|---------| | Meeting warning | Red alert when ≤5m away | Meeting in 3m - wrap up! | | Upcoming (within threshold) | In Xm: Title (account) | In 15m: Team Standup (work) | | Current | Now: Title (account) | Now: Team Standup (work) | | Later | HH:MM AM/PM: Title (account) | 2:30 PM: Meeting (work) | | No events | No upcoming events | |

Zoho Tasks

| State | Color | Example | |-------|-------|---------| | Overdue task | Red | Overdue task title | | High priority | Yellow | High priority task | | Normal task | White | Normal task title |

Tasks are displayed as: Tasks: Task 1, Task 2, Task 3

Health Reminders (~5% chance)

| Type | Color | Example | |------|-------|---------| | Water | Cyan | Stay hydrated! Drink some water | | Stretch | Green | Time to stretch! Stand up and move | | Eye break | Magenta | Eye break! Look 20ft away for 20s |

Configuration

All configuration is stored in ~/.glancebar/:

~/.glancebar/
├── config.json              # User settings
├── credentials.json         # Google OAuth credentials (you provide)
├── zoho_credentials.json    # Zoho OAuth credentials (you provide)
└── tokens/                  # OAuth tokens per account
    ├── google_<email>.json  # Google tokens
    └── zoho_<email>.json    # Zoho tokens

Default Settings

| Setting | Default | Description | |---------|---------|-------------| | lookaheadHours | 8 | Hours ahead to look for events | | countdownThresholdMinutes | 60 | Minutes threshold for countdown display | | maxTitleLength | 120 | Maximum event title length | | showCalendarName | true | Show account name after event | | waterReminderEnabled | true | Enable random water break reminders | | stretchReminderEnabled | true | Enable random stretch/posture reminders | | eyeReminderEnabled | true | Enable random eye break reminders (20-20-20 rule) | | showCpuUsage | false | Show CPU usage percentage | | showMemoryUsage | false | Show memory usage | | showZohoTasks | true | Show pending Zoho tasks | | maxTasksToShow | 3 | Maximum number of tasks to display |

Building from Source

# Clone the repository
git clone https://github.com/vishal-android-freak/glancebar.git
cd glancebar

# Install dependencies
bun install

# Run locally
bun run dev

# Build binaries for all platforms
bun run build:all

Build Targets

| Platform | Command | |----------|---------| | Linux x64 | bun run build:linux-x64 | | Linux ARM64 | bun run build:linux-arm64 | | macOS x64 | bun run build:darwin-x64 | | macOS ARM64 | bun run build:darwin-arm64 | | Windows x64 | bun run build:win-x64 |

Roadmap

  • [ ] Task integration (Todoist, Google Tasks)
  • [ ] Weather information
  • [ ] System stats
  • [ ] Custom modules

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Author

Vishal Dubey (@vishal-android-freak)

License

MIT