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

@yukiakai/gitenv

v1.0.0

Published

A flexible find-up implementation supporting string, RegExp, CJS/ESM dual build, and custom matcher.

Readme

@yukiakai/gitenv

Sync and manage environment files across machines safely using a private Git repository, with profile-based configuration.


Why?

Developers often:

  • accidentally commit .env files
  • lose environment variables
  • duplicate configs across machines

gitenv solves this by:

  • storing your env files in a separate private repo
  • syncing them via simple commands
  • keeping your main repo clean and safe

Features

  • Sync .env files between local and remote repo
  • Profile-based configuration (like prod, local, ci)
  • Config inheritance via extends
  • Glob support (**/*.env)
  • Smart ignore
  • Diff preview (optional)
  • Prune mode (remove stale files)
  • Fast & deterministic sync

Installation

npm install -g @yukiakai/gitenv

Quick Start

1. Create a private repo

Create a Git repository (GitHub, GitLab, etc.):

my-env-store (private)

2. Initialize

gitenv init <repo-url>  --project-name <name>

Example:

gitenv init [email protected]:you/env-store.git --project-name gitenv

This will:

  • create gitenv.config.json
  • create .gitenv/ folder
  • add .gitenv to .gitignore

Project name is used as a unique identifier for syncing your environment variables. Changing this name later will make existing env data inaccessible.


3. Configure tracked files

Edit:

gitenv.config.json
{
"default": {
  "repo": "[email protected]:you/env-store.git",
  "tracked": [
    ".env",
    "apps/api/.env"
  ]
}
}

4. Push your env

gitenv push -m "update env"

5. Pull on another machine

gitenv pull

Profiles

Profiles define how env files are synced.

Select a profile using:

GITENV_PROFILE="name"

Example config

{
  "default": {
    "repo": "[email protected]:your/env-repo",
    "projectName": "my-app",
    "tracked": ["**/*.env"],
    "ignore": [],
    "strict": false,
    "diff": true,
    "version": 1
  },

  "prod": {
    "extends": ["default"],
    "tracked": [".env.prod"]
  },

  "local": {
    "extends": ["default"],
    "ignore": [".env.local"]
  }
}

gitenv example

Generate .env.example from .env

gitenv example .env
gitenv example -p profile

Backup

Before overwriting files on pull, gitenv creates a backup:

.gitenv/backups/

You can restore manually.


Safety

  • .gitenv is automatically added to .gitignore
  • prevents leaking env data into your main repo

Do not remove it.


Recommended workflow:

gitenv push   # before switching machine
gitenv pull   # on another machine

License

MIT