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

pi-env-reload

v0.2.0

Published

Reload .env credentials in a running Oh My Pi or Pi session

Readme

pi-env-reload

npm version npm downloads CI license

Reload API credentials from a dotenv file in a running Oh My Pi or Pi session, without a restart.

Install

Oh My Pi

omp plugin install npm:pi-env-reload

Pi

pi install npm:pi-env-reload

Start a new session after installing the package. Extensions are discovered when the session starts.

Use

Edit the dotenv file for your harness, then run this command in the active session:

/env-reload

The command waits for any active request to finish, reloads the file into the running process, and rebuilds the model registry. This supports credentials referenced by static models.yml entries, including custom providers whose apiKey points at a variable such as REFRESHER_ANTHROPIC_KEY.

The command reports only a generic success or error message. It never prints credential values.

Which dotenv file?

  • Oh My Pi: ~/.omp/.env (or the active profile's .env).

  • Pi: set PI_ENV_RELOAD_CONFIG_DIR to the Pi config directory holding the dotenv file, e.g. ~/.pi/agent:

    PI_ENV_RELOAD_CONFIG_DIR=$HOME/.pi/agent pi

    Without the override the extension reads the ~/.omp default, so Pi users must set it once (export it in your shell profile).

Auto reload

The reload stays explicit by default. To pick up rotated credentials without running /env-reload, opt in with PI_ENV_RELOAD_AUTO in the dotenv file:

PI_ENV_RELOAD_AUTO=5m

Every tick compares the dotenv file's mtime and size against the last applied reload, so an unchanged file costs nothing. On a change the extension applies the values while the agent is idle, rebuilds the model registry, and shows one (auto) notification. Accepted formats: 5m, 30s, 1h, or a bare number of seconds (300). off (or unsetting the variable) disables it, and values below a 30-second floor are clamped.

Scope and limitations

  • The extension reloads the dotenv file at the configured config root: ~/.omp/.env on OMP (or the active profile's .env), and the PI_ENV_RELOAD_CONFIG_DIR path on Pi.
  • Pi support requires PI_ENV_RELOAD_CONFIG_DIR; without it Pi reads the ~/.omp default, which does not match Pi's ~/.pi/agent layout.
  • It updates the current process only. Child shells and future OMP processes use their own environment.
  • Values supplied by a !command entry in models.yml remain subject to OMP's command-result cache.
  • Auto reload never mutates the environment or rebuilds the registry during an active request; the change is picked up on a later tick once the agent is idle. A manual /env-reload still waits for the active request to finish.

Develop

npm install
npm run typecheck
npm test
npm pack --dry-run