Secure .env encryption for git commits.
npm install -g nextdotenv
# or
npx nextdotenv <command>| Command | Description |
|---|---|
backup |
Encrypt .env → crypted.env |
restore |
Decrypt crypted.env → .env |
update |
Re-encrypt after changes |
diff |
Compare .env with crypted.env |
rotate |
Change encryption password |
status |
Show file status (no password) |
verify |
Check if password is correct |
template |
Create .env.example from .env |
web |
Start web interface |
# Encrypt
npx nextdotenv backup
# Decrypt
npx nextdotenv restore
# Re-encrypt after changes
npx nextdotenv update
# Check status
npx nextdotenv status
# Verify password
npx nextdotenv verify
# Compare changes
npx nextdotenv diff
# Create .env.example
npx nextdotenv template
# Web interface
npx nextdotenv web- AES-256-GCM encryption
- PBKDF2 (100k iterations)
- Unique salt and IV per backup
- Rate limiting on web interface
MIT