ee is a CLI tool that brings structure and validation to environment variable management. It enables teams to define, validate, and manage environment variables across different environments with schema-based validation and inheritance support.
- Schema-based validation with type checking
- Support for multiple environments (dev, staging, prod)
- Variable inheritance between environments
- Regex pattern validation
- Default values
- Required field enforcement
- Multiple export formats (.env, JSON, YAML)
- Cross-platform support (Linux, macOS, Windows)
- Editor integration for configuration
- Comprehensive logging system
Install the latest version with a single command:
curl -sSfL https://raw.githubusercontent.com/n1rna/ee/main/install.sh | sh# Using Go
go install github.com/n1rna/ee/cmd/ee@latest
# Download specific version
curl -sSfL https://raw.githubusercontent.com/n1rna/ee/main/install.sh | sh -s -- --version v1.0.0
# From source
git clone https://github.com/n1rna/ee.git
cd ee
make install- Download the appropriate binary for your platform from the releases page
- Make it executable:
chmod +x ee - Move it to your PATH:
sudo mv ee /usr/local/bin/
ee version- Create a new project with a schema:
ee new myproject- Create different environments:
ee new myproject --env development
ee new myproject --env production- Edit environment variables:
ee edit myproject --env development- Apply variables and run commands:
# Start a shell with the environment loaded
ee apply myproject --env development
# Run a command with the environment
ee apply myproject --env development -- npm startname: myproject-schema
variables:
- name: BASE_URL
type: string
regex: "^https?://.*$"
default: "http://localhost:8000"
required: true
- name: DEBUG
type: boolean
default: "false"
required: true
- name: API_KEY
type: string
required: trueee new [project-name]- Create a new projectee new [project-name] --env [env-name]- Add new environmentee edit [project-name] --env [env-name]- Edit environment variablesee apply [project-name] --env [env-name] [-- command]- Apply variablesee export [project-name] --env [env-name] -f [format]- Export configurationee set [project-name] --env [env-name] KEY=VALUE...- Set variablesee env [-e envfile] [-- command]- Apply from .env file
ee stores all data in ~/.ee/ by default. You can override this with:
ee_HOMEenvironment variable--dirflag in commands
Directory structure:
~/.ee/
├── schemas/ # Schema definitions
└── projects/ # Project configurations
└── myproject/
├── development.yaml
└── production.yaml
# Install dependencies
make deps
# Build
make build
# Run tests
make test
# Install locally
make install- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
MIT License - see the LICENSE file for details