A Ruby gem that ensures presence and type correctness of environment variables, providing typed access.
ENVied is a Ruby gem that validates the presence and type of environment variables in applications. It ensures required configuration variables exist and can be coerced into proper types like integers or booleans, preventing runtime errors. The gem provides typed access to ENV variables, replacing string-only values with Ruby-native types.
Ruby developers, particularly those working on Rails applications or any Ruby project that relies on environment variables for configuration. It's useful for teams needing robust configuration validation and type safety.
Developers choose ENVied for its focused approach to environment variable validation without the complexity of loading values. It integrates seamlessly with Heroku, supports environment-specific groups, and offers a CLI for easy checks, reducing configuration-related bugs.
Ensures presence and type of your app's ENV-variables (mirror)
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Converts ENV strings to proper Ruby types like integers, booleans, arrays, and URIs, as detailed in the Types section, reducing runtime errors.
Allows defining variables for different environments (e.g., development, production) using group blocks, ensuring only relevant configs are required during initialization.
Includes CLI tools like `envied check:heroku` to verify Heroku app configs before deployment, preventing boot failures due to missing variables.
Provides an extraction command to scan codebases and find all ENV usage, aiding in migrating existing projects to typed access, as shown in the CLI section.
Explicitly marked as discontinued in the README, with a link to a replacement, posing risks for long-term dependency management and security updates.
Deliberately omits support for inline default values, requiring external files like .envrc.sample and tools such as direnv, as admitted in the FAQ.
Key alias and env-type features are labeled 'unreleased' in the documentation, indicating incomplete or unstable functionality that may not be reliable.
Best practices recommend using direnv for environment management, adding complexity and an extra dependency beyond the gem itself.