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

@varshiljpatel/nenv

v0.0.5

Published

No need to manage .env files. Just use nenv!

Readme

nenv

License
npm version

Problem Statement

Managing .env files in modern applications can be cumbersome and error-prone. Developers often face challenges such as:

  • Accidentally committing sensitive .env files to version control.
  • Manually managing .env files across multiple environments (e.g., development, staging, production).
  • Lack of encryption for .env files, leaving sensitive data exposed.

These issues can lead to security vulnerabilities, inefficiencies, and unnecessary complexity in managing environment variables.


Solution: nenv

nenv is a CLI tool designed to simplify and secure the management of .env files. With nenv, you can:

  • Encrypt your .env files into .nenv files, ensuring sensitive data is protected.
  • Decrypt .nenv files back into .env files when needed.
  • Specify custom paths and filenames for .env and .nenv files.
  • Automatically update your .gitignore file to exclude .nenv files from version control.

nenv ensures that your environment variables are secure and easy to manage across different environments.


Features

  • 🔒 Encryption: Securely encrypt .env files into .nenv files using AES-256 encryption.
  • 🔓 Decryption: Decrypt .nenv files back into .env files when needed.
  • 📂 Custom Paths: Specify custom paths and filenames for .env and .nenv files.
  • 🛠️ Cross-Platform: Works seamlessly on Windows, macOS, and Linux.
  • 📜 Automatic .gitignore Updates: Automatically adds .nenv files to your .gitignore file to prevent accidental commits.

Installation

You can install nenv using your favorite package manager:

npm

npm install -g @varshiljpatel/nenv

pnpm

pnpm add -g @varshiljpatel/nenv

yarn

yarn global add @varshiljpatel/nenv

bun

bun add -g @varshiljpatel/nenv

You can also access the cli via nenv ... and no.env ... command.

Usage

Encrypting .env Files

To encrypt a .env file into a .nenv file, use the encrypt command:

nenv encrypt <password>

Options:

  • --env <path>: Path to the .env file (default: ./).
  • --name <filename>: Name of the .env file (default: .env).
  • --output <path>: Directory where the .nenv file will be saved (default: ./).

Example:

nenv encrypt mypassword --env=./src/frontend --name=.env.local --output=./src/frontend

This command:

  • Encrypts the .env.local file located in ./src/frontend.
  • Saves the encrypted .nenv file in the ./src/frontend directory.

Decrypting .nenv Files

To decrypt a .nenv file back into a .env file, use the decrypt command:

nenv decrypt <password>

Options:

  • --env <path>: Path to the .nenv file (default: ./).
  • --name <filename>: Name of the output .env file (default: .env).

Example:

nenv decrypt mypassword --env=./src/frontend --name=.env.local

This command:

  • Decrypts the .nenv file located in ./src/frontend.
  • Saves the decrypted .env.local file in the same directory.

Automatic .gitignore Updates

nenv automatically updates your .gitignore file to include the .nenv file. This ensures that encrypted files are not accidentally committed to version control.


How It Works

Encryption

  1. Reads the contents of the .env file.
  2. Encrypts the contents using AES-256 encryption with a user-provided password.
  3. Saves the encrypted data as a .nenv file in the specified output directory.

Decryption

  1. Reads the contents of the .nenv file.
  2. Decrypts the contents using AES-256 decryption with the same password used for encryption.
  3. Saves the decrypted data as a .env file in the specified directory.

Supported Platforms

nenv is built using Rust and Node.js, making it compatible with the following platforms:

  • Windows
  • macOS
  • Linux

License

This project is licensed under the Apache License 2.0. See the LICENSE file for details.


Contributing

Contributions are welcome! If you'd like to contribute, please:

  1. Fork the repository.
  2. Create a new branch for your feature or bugfix.
  3. Submit a pull request.

Author

This project is developed and maintained by Varshil J Patel.


Acknowledgments

  • Built with ❤️ using Rust and Node.js.
  • Inspired by the need for secure and efficient environment variable management.

Feedback

If you encounter any issues or have suggestions for improvement, please open an issue on the GitHub repository.


Keywords

  • nenv
  • .nenv
  • environment variables
  • secure env management
  • encryption
  • decryption
  • node.js
  • rust

Future Plans

  • Add support for additional encryption algorithms.
  • Provide a GUI for managing .env and .nenv files.
  • Add integration with cloud-based secret management tools.

Thank you for using nenv! 🎉