@fukkyuhh3/cleanenv
v1.0.2
Published
Generate a .env.example from your .env file automatically
Maintainers
Readme
@fukkyuhh3/cleanenv
Automatically generate a .env.example file from your .env file.
Why?
Every project uses a .env file for secrets like API keys and passwords. You cannot commit it to GitHub, but teammates need to know which variables exist. cleanenv generates a .env.example with all the keys intact but values replaced by readable placeholders — automatically.
Install
npm install -g @fukkyuhh3/cleanenv
Usage
Run inside any project with a .env file:
cleanenv
Or point it at a specific folder:
cleanenv /path/to/project
Example
Input .env: API_KEY=supersecret123 DATABASE_URL=postgres://user:pass@localhost/db PORT=3000
Output .env.example: API_KEY=YOUR_API_KEY_HERE DATABASE_URL=YOUR_DATABASE_URL_HERE PORT=YOUR_PORT_HERE
Comments and blank lines are preserved unchanged.
License
ISC
