Linux command
dotenvx 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Run command with .env loaded
dotenvx run -- [command]
Run with specific env file
dotenvx run -f [.env.production] -- [command]
Encrypt env file
dotenvx encrypt
Decrypt env file
dotenvx decrypt
Set a key
dotenvx set [KEY] [value]
Get a key
dotenvx get [KEY]
Convert to encrypted format
dotenvx convert
说明
dotenvx is an enhanced dotenv tool that loads environment variables from .env files with support for encryption. It extends the traditional dotenv pattern with built-in encryption capabilities, allowing teams to securely commit encrypted environment files to version control. The tool supports multiple environment files (.env.production, .env.staging), automatic decryption at runtime, and key management for team-based secret sharing. It provides a modern approach to managing application secrets without external secret management services.
参数
- -f, --env-file _file_
- Path to env file.
- --overload
- Override existing env vars.
FAQ
What is the dotenvx command used for?
dotenvx is an enhanced dotenv tool that loads environment variables from .env files with support for encryption. It extends the traditional dotenv pattern with built-in encryption capabilities, allowing teams to securely commit encrypted environment files to version control. The tool supports multiple environment files (.env.production, .env.staging), automatic decryption at runtime, and key management for team-based secret sharing. It provides a modern approach to managing application secrets without external secret management services.
How do I run a basic dotenvx example?
Run `dotenvx run -- [command]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -f, --env-file _file_ do in dotenvx?
Path to env file.