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

@ftirelo/triage-cli

v0.1.8

Published

Declarative Gmail filter management — version-controlled rules synced to Gmail with dry-run, snapshot, and rollback safety

Readme

@ftirelo/triage-cli

Declarative Gmail filter management from the command line.

Triage lets you manage Gmail filters and labels declaratively: rules live in a version-controllable JSON format, and the triage CLI syncs them to Gmail with a dry-run-by-default, confirm, snapshot, apply safety flow. Instead of clicking through Gmail's settings, you describe the desired state of your inbox and let Triage compute and apply the diff — reversibly.

Install

Requires Node.js 20+.

npm install -g @ftirelo/triage-cli
triage --version

Quick start

triage auth login                       # browser sign-in handoff; caches a token
triage whoami                           # confirm which Gmail account you're using

triage import --from rules.json         # load rules from a file…
triage import --from-gmail              # …or reverse-import your existing filters
triage list                             # view stored rules

triage sync                             # DRY-RUN (default): print the plan, change nothing
triage sync --apply                     # confirm + snapshot + apply to Gmail

triage status                           # detect drift between Gmail and your rules
triage history --audit                  # review syncs, snapshots, and the audit log

triage snapshot --label "before cleanup"
triage rollback --apply                 # restore the most recent snapshot

Commands

| Command | What it does | | :---------------- | :--------------------------------------------------------------------- | | triage auth | login / status / logout — browser sign-in handoff | | triage whoami | Show the signed-in Gmail address | | triage import | Load rules from rules.json or reverse-import from Gmail | | triage list | List stored rules with query and actions; --json for raw output | | triage sync | Diff rules vs. Gmail; --apply to mutate, --yes for non-interactive | | triage status | Read-only drift report | | triage snapshot | Capture the current Gmail filter state as a restore point | | triage rollback | Preview/apply a snapshot restore (dry-run by default) | | triage history | Recent syncs and snapshots; --audit adds the audit log |

Rules format

Each rule is a Gmail search query plus one or more actions (archive, markRead, addLabel, removeLabel, star):

{
  "version": 1,
  "rules": [
    {
      "id": "github-notifications",
      "name": "GitHub notifications → label + archive",
      "query": "from:[email protected]",
      "actions": [{ "type": "addLabel", "label": "Dev/GitHub" }, { "type": "archive" }]
    }
  ]
}

Safety rails

  • No destructive actions — there is no delete/trash/spam action; the schema rejects anything else. Triage never deletes mail.
  • Dry-run is the default for sync and rollback; --apply is required to mutate, and prompts for confirmation unless --yes is passed.
  • Automatic snapshots before every sync and rollback, so changes are reversible.

Documentation

Full documentation, the rules starter file, and the web dashboard live in the gmail-filters repository.

License

MIT