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

@ifi/pi-background-tasks

v0.5.1

Published

Reactive background shell tasks for pi with /bg, Ctrl+Shift+B, log viewing, and agent wakeups on output.

Readme

@ifi/pi-background-tasks

Reactive background shell tasks for pi.

Install

pi install npm:@ifi/pi-background-tasks

Or install the full default oh-pi bundle, which also includes the compatible bg-process shim:

npx @ifi/oh-pi

What it provides

This package turns explicit background shell commands into a first-class pi workflow:

  • ordinary bash commands stay in the foreground and use pi's built-in execution flow
  • bg_status — compatibility tool for listing, tailing, and stopping tracked background tasks by PID
  • bg_task — richer LLM-callable tool for spawning, listing, tailing, stopping, and clearing tasks by id or PID
  • /bg — slash command for launching and managing background tasks manually
  • Ctrl+Shift+B — richer multi-pane dashboard overlay with a task list, metadata pane, and scrollable log tail
  • /bg watch --follow <id> — jump straight into the output pane for a task with follow-tail mode enabled
  • reactive follow-ups — pi can wake itself up when watched tasks emit new output or exit
  • persistent log files for every spawned task

Example flows

/bg run gh pr checks 123 --watch
/bg run pnpm test --watch
/bg watch bg-1
/bg watch --follow bg-1
/bg stop bg-1

The bg_task tool lets the agent start tasks explicitly and optionally gate wakeups with a substring or /regex/flags pattern.

The dashboard supports:

  • Tab to switch between the task list and output pane
  • ↑↓, Shift+↑, Shift+↓, Home, and End for navigation
  • f to toggle follow-tail mode
  • s to stop the selected task
  • c to clear finished tasks

Notes

  • tasks are tracked for the current pi runtime and cleaned up on session shutdown
  • every task writes output to a log file so you can inspect recent activity even after the command returns
  • use bg_task or /bg for servers, watchers, PR checks, and other commands you want to keep running after the tool returns
  • reactToOutput defaults to true, so long-lived watchers like gh ... --watch can wake the agent when new output arrives

This package ships raw .ts sources for pi to load directly.