Folder Mapping
lazyenv maps local paths to secret paths using workspace folders.
Folder configuration
Section titled “Folder configuration”Each .env.example file becomes a workspace folder:
{ "workspaceFolders": [ { "path": ".", "secretPath": "/", "envFile": ".env.example", "keys": ["DATABASE_URL", "API_KEY"] }, { "path": "apps/web", "secretPath": "/apps/web", "envFile": "apps/web/.env.example", "keys": ["NEXT_PUBLIC_API_URL"] } ]}Path mapping
Section titled “Path mapping”| Local Path | Secret Path | Purpose |
|---|---|---|
. | / | Root folder |
apps/web | /apps/web | Web app |
apps/api | /api | API service (custom) |
packages/shared | /packages/shared | Shared package |
Auto‑detection
Section titled “Auto‑detection”lazyenv automatically detects your current folder:
cd apps/weblazyenv sync # Automatically uses /apps/web folderCustom mappings
Section titled “Custom mappings”You can edit .lazyenv/config.json to customize secret paths:
{ "path": "apps/api", "secretPath": "/api", // Custom path (shorter) "envFile": "apps/api/.env.example"}