Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Custom Env VarsNew to Visual Studio Code? Get it now.
Custom Env Vars

Custom Env Vars

zqchen

|
3 installs
| (0) | Free
Inject custom environment variables into VS Code integrated terminals
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Custom Env Vars

Inject custom environment variables into VS Code integrated terminals.

Pre-defined Variables

Variable Description
ZDEV_MULTIROOT_WORKSPACE "true" if inside a multi-root workspace, "false" otherwise
ZDEV_MULTIROOT_PATH Colon-separated absolute paths of all workspace folders. Empty string if not a multi-root workspace

User-defined Variables

Add custom environment variables via settings.json:

{
  "customEnvVars.variables": {
    "MY_VAR": "my_value",
    "ANOTHER_VAR": "another_value"
  }
}

All variables (both pre-defined and user-defined) are injected into every new integrated terminal session and persist across window reloads.

Configurations

Key Description Type Default
zdev.customEnvVars.variables Custom environment variables to inject into integrated terminals. Keys are variable names, values are variable values. object {}

License

MIT

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft