/ Search - type / Modes - type M Star on GitHub - 5.7k

dotenvx get

-f directory

Return an environment variable from the .env file in a directory. This is useful with monorepos.

Usage

From a workspace, point -f at the monorepo root to read its .env:

$ cd apps/web

dotenvx get HELLO -f ../..
World

When .env.keys sits beside the resolved .env, encrypted values are decrypted automatically.