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

@lucasmarkes/envfy

v1.0.2

Published

Simple CLI tool to manage .env environments easily

Readme

Envfy 🚀

Envfy is a simple and developer-friendly CLI tool to manage multiple .env environments for your projects. It helps developers quickly create, switch, and manage environment files (.env.local, .env.dev, .env.stage, .env.prod) and also generates a .env.example file for sharing with your team.

Built with developer experience (DX) in mind. Keep your workflow simple, consistent, and hassle-free.


Features ✨

  • Interactive creation of .env.* files
  • Optional environment variable creation
  • .env.example automatically generated
  • Switch between environments easily
  • Set or update variables in specific environment files
  • Check which environment is currently active
  • Custom help command for quick reference

Installation 💻

You can install Envfy globally via npm:

npm install -g @lucasmarkes/envfy

Or clone and link locally for development:

git clone https://github.com/lucasmarkes/envfy.git
cd envfy
npm install
npm run build
npm link

Usage 🚀

After installation, you can use envfy globally in your terminal.

Initialize environments

envfy init
  • Interactive prompt asks if you want to create environment variables
  • Generates .env.local, .env.dev, .env.stage, .env.prod
  • Generates .env.example as a template
  • All variable values are empty by default

Example interaction:

Do you want to create environment variables now? (y/N) y
How many environment variables do you want to create? 3
Enter name for variable #1: API_URL
Enter name for variable #2: DB_USER
Enter name for variable #3: DB_PASS
✅ Created: .env.local
✅ Created: .env.dev
✅ Created: .env.stage
✅ Created: .env.prod
✅ Created: .env.example

List available environments:

envfy list

Example output:

Available environments:
  - local
  - dev
  - stage
  - prod

Switch environment

envfy switch dev
  • Copies .env.dev to .env in your project root
  • Makes switching between environments fast and safe

Set or update variables

envfy set API_URL https://api.dev --env dev
  • Sets or updates a variable in a specific .env.* file
  • Default target environment is local if --env is not provided

Show active environment

envfy status

Example output:

🌱 Active environment (.env):
API_URL=https://api.dev
DB_USER=root
DB_PASS=secret

Help command

envfy help

Shows all commands, descriptions, and examples:

Envfy - CLI to manage multiple .env environments

Commands:
  init               Create .env files (optional variables)
  list               List available environments
  switch <env>       Switch to the specified environment
  set <key> <value>  Set or update a variable in a specific .env file
  status             Show which environment is currently active
  help               Show this help message

Examples:
  envfy init
  envfy set API_URL https://api.dev --env dev
  envfy switch dev

Project Philosophy 💡

Envfy is built with developer experience in mind:

  • Minimal setup and fast execution
  • Optional interactive creation of environment variables
  • Encourages best practices with .env.example
  • Helps teams and open source projects manage environments safely

Contributing 🤝

Contributions are welcome! Feel free to:

  • Submit bug reports
  • Suggest new features
  • Open pull requests

License 📄

MIT License. See License: MIT for details.


Stay Connected 🔗

Follow updates, share feedback, and connect on Twitter: @lucasmarkes__