Stand
A CLI tool for explicit environment variable management that provides a clean, organized way to handle different environments (dev, staging, prod) with their specific configurations.
Quick Start
Installation
From crates.io (recommended):
From source:
Basic Usage
-
Initialize a new project:
-
List available environments:
-
Show variables for an environment:
-
Execute command with environment:
Configuration Example
Create a .stand.toml file in your project root:
= "2.0"
[]
= true # Prevent navigation outside project directory
[]
= "MyApp"
= "json"
[]
= "Development environment"
= "green"
= "postgres://localhost:5432/dev"
= "true"
[]
= "Production environment"
= "red"
= "dev"
= true
= "postgres://prod.example.com/myapp"
= "false"
See Configuration Format for all available settings.
Features
- Environment Management: Define and switch between multiple environments
- Variable Inheritance: Use
extendsto inherit from other environments - Variable Interpolation: Reference system environment variables with
${VAR} - Shell Integration: Start shell sessions with environment loaded
- Command Execution: Execute commands with specific environment variables
- Configuration Validation: Validate configuration file syntax and structure
Examples
Learn by example! Check out the examples/ directory for practical demonstrations:
- basic/ - Simple environment setup (dev, prod)
- inheritance/ - Using
extendsfor environment inheritance - web-app/ - Realistic web application configuration
- interpolation/ - Variable interpolation with
${VAR}syntax
Each example includes a complete .stand.toml configuration and usage instructions. See the Examples README for detailed walkthroughs.
Documentation
User Documentation
- CLI Commands - Complete command reference
- Configuration Format - Configuration file syntax and examples
Developer Documentation
- Architecture Overview - High-level system design
- Development Guidelines - TDD workflow and build commands
- Design Documentation - Detailed design decisions
- Requirements - Feature specifications
- PR Review Guidelines - Pull request checklist
AI Assistant Documentation
- AGENTS.md - AI assistant instructions and development guidelines
CLAUDE.mdis a symlink to this file for Claude Code compatibility
Development
Prerequisites
- Rust 2021 edition
- Cargo
Setup
Running Tests
Code Quality
&& &&
Command Implementation Status
- ✅
list- List all available environments - ✅
validate- Validate configuration file - ✅
current- Show current environment status - ✅
init- Initialize new configuration - ✅
shell- Start interactive shell with environment loaded - ✅
exec- Execute command with environment variables - ✅
show- Show environment variables with source attribution - ✅
env- Show active environment variables in current subshell - 🚧
set/unset- Modify environment variables (planned)
Contributing
- Read the development guidelines
- Follow the TDD workflow (RED → GREEN → REFACTOR)
- Create feature branches from
main - Ensure all tests pass before submitting PR
- Follow the PR review guidelines
License
MIT License - see LICENSE file for details.
Support
- Issues: GitHub Issues
- Documentation: See
docs/directory - Development: See AGENTS.md for AI assistant guidelines