env
A highly secure Go environment variable management library with support for .env, JSON, and YAML formats, providing thread safety, audit logging, and secure storage.
Core Features
- Multi-format Support - Automatic detection of
.env, JSON, YAML - Type Safety - Automatic type conversion and validation
- Thread Safety - Thread-safe concurrent access with sharded locks
- Secure Storage - Memory locking and auto-zeroing for sensitive values
- Audit Logging - Complete operation tracking
- Variable Expansion -
${VAR}syntax support - Struct Mapping - Tag-driven configuration binding
Feature Overview
| Feature | Description |
|---|---|
| Type Conversion | GetString, GetInt, GetBool, GetDuration, GetSlice |
| Struct Mapping | Tag-driven configuration binding |
| Secure Storage | Sensitive value memory protection |
| Multi-format Loading | .env, JSON, YAML |
Quick Navigation
Getting Started
- Getting Started - 5-minute tutorial
- Cheat Sheet - Common code snippets
API Reference
- Package Functions - Complete API documentation
- Loader - Loader methods
- SecureValue - Secure value handling
Security
- Security Overview - Security architecture and best practices