render_env
Renders environment variables for the current project slot in dotenv, export, JSON, or other formats, and leases ports for services without one. Outputs ready-to-use env files for local development.
Instructions
Every environment variable of the current slot (service ports, derived values, PORT_KEEPER_PROJECT/SLOT) in a format: dotenv, export, json, mise, direnv or claude-env. Leases ports for services that have none yet. For your own use: to write .env.local run the port-keeper env command instead of writing the file by hand, and do not echo these numbers to the user.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | directory to resolve the project from; defaults to where the server was started | |
| format | No | dotenv, export, json, mise, direnv or claude-env (default export) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| env | Yes | ||
| slot | Yes | ||
| text | Yes | the rendered snippet | |
| format | Yes | ||
| project | Yes |