A Zsh plugin that automatically sources .in and .out files when entering or leaving directories.
Autoenv is a Zsh plugin that automatically sources shell scripts (`.in` and `.out` files) when entering or leaving directories. It solves the problem of manually setting up project-specific environments, such as configuring Node.js versions or environment variables, by automating these tasks based on directory changes.
Zsh users, particularly developers who work on multiple projects with different environment requirements and want to automate their shell setup.
Developers choose Autoenv for its simplicity and automation, eliminating repetitive manual environment configuration and ensuring consistent shell states across projects with minimal setup.
Autoenv for zsh
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Automatically sources .in and .out files when entering or leaving directories, as demonstrated in the README's cd examples, eliminating manual configuration for project-specific settings like Node.js versions.
Allows overriding default .in and .out file names via $AUTOENV_IN_FILE and $AUTOENV_OUT_FILE environment variables, providing flexibility to match project conventions or avoid conflicts.
Only sources known/whitelisted files to prevent arbitrary script execution, enhancing security compared to unrestricted sourcing, which is a key feature mentioned in the README.
Passes the directory path as the first argument to scripts, supporting symlink usage, as noted in the README, enabling flexible project structures without relying on pwd.
Exclusively works with Zsh, making it incompatible with other shells like Bash, which restricts its use in mixed-shell development environments.
Requires the zsh-colors plugin to be installed and activated separately, adding setup complexity and a potential point of failure, as stated in the prerequisites.
Uses .in and .out files instead of common .env, which was changed to avoid conflicts but may confuse users accustomed to standard .env files for environment configuration.
Safety relies on users manually managing whitelisted files, which can be error-prone and less secure if not diligently maintained, despite the whitelist feature.