Repository navigation
v0.1.0 - Initial npm release
envspec v0.1.0
π Initial Release
A schema-driven CLI tool for validating, generating, and protecting environment variables.
β¨ Features
- Type-safe validation - Validate
string,number,boolean,array, andobjecttypes - Schema inference - Generate schemas from existing
.envfiles - Auto-generation - Create
.envtemplates from schema with smart merging - Git protection - Automatically protect env files from commits
- Enum validation - Restrict values to specific options
- CI/CD ready - Exit codes for pipeline integration
π¦ Installation
npm install -g envspecRequirements: Node.js >= 18
π Quick Start
envspec init --from-env # Generate schema from .env
envspec validate # Validate environment
envspec git-protect # Protect from gitπ Security
Schemas contain NO actual values - only structure and types. Your secrets stay in .env files (local only).
π Documentation
Full docs: https://github.com/akshayxemo/envspec#readme
Full Changelog: https://github.com/akshayxemo/envspec/commits/v0.1.0