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

tonton-cli

v1.1.7

Published

Play a notification sound from the CLI. Zero dependencies. Perfect for AI coding tool hooks.

Readme

tonton

Play a notification sound from your terminal. Zero dependencies. ~15KB.

Perfect for getting pinged when AI coding tools (Claude Code, Codex, etc.) finish a task — or need your attention.

Quick Start

npx tonton-cli --setup

That's it. Claude Code will now play:

  • A done sound when the agent finishes
  • An input sound when the agent needs you

Install

npm install -g tonton-cli

Or use without installing — npx tonton-cli works everywhere.

Two Sounds

| Command | When | macOS | Cross-platform | |---------|------|-------|---------------| | tonton --done | Agent finished | Glass | Descending chime | | tonton --input | Agent needs you | Funk | Ascending chime |

tonton --done     # hear the "finished" sound
tonton --input    # hear the "need attention" sound
tonton            # default notification sound

Use with AI CLI Tools

Claude Code — automatic setup

npx tonton-cli --setup

This adds hooks to ~/.claude/settings.json so Claude Code plays distinct sounds when done vs. needing input. Run once, works forever.

Updating? Just run --setup again — it removes old hooks before adding new ones, so there's no doubling:

npm update -g tonton-cli
tonton --setup

To remove: npx tonton-cli --remove

Claude Code — manual setup

Add to ~/.claude/settings.json:

{
  "hooks": {
    "Stop": [
      { "matcher": "", "hooks": [{ "type": "command", "command": "npx tonton-cli --done" }] }
    ],
    "PermissionRequest": [
      { "matcher": "", "hooks": [{ "type": "command", "command": "npx tonton-cli --input" }] }
    ]
  }
}

Codex CLI

codex "fix the bug" ; npx tonton-cli --done

Any command

npm test ; npx tonton-cli --done
long-running-task ; npx tonton-cli

Shell alias

# Add to ~/.zshrc or ~/.bashrc
notify() { "$@"; npx tonton-cli --done; }

# Then use:
notify npm test
notify codex "refactor this"

More Options

# Pick a specific sound (macOS system sounds)
tonton --sound Glass
tonton --sound Hero

# Adjust volume (macOS only)
tonton --volume 0.5

# List available sounds
tonton --list

Programmatic API

import { play, listSounds } from 'tonton-cli';

await play();                          // default sound
await play({ sound: 'done' });         // completion sound
await play({ sound: 'input' });        // attention sound
await play({ sound: 'Glass' });        // macOS system sound
await play({ volume: 0.5 });           // half volume (macOS)

const sounds = listSounds();           // available sound names

Cross-Platform

| Platform | Player | Sounds | |----------|--------|--------| | macOS | afplay (built-in) | 14 system sounds + synthesized chime | | Linux | paplay / aplay / ffplay | Freedesktop sounds + synthesized chime | | Windows | PowerShell SoundPlayer | Windows Media sounds + synthesized chime |

Falls back to a synthesized two-tone chime, then terminal bell — always plays something.

Always exits 0. A notification sound will never break your scripts, hooks, or CI.

License

MIT