.env file

If you change your launch.json settings regularly, or don't want to check certain values into version control, then another option is to store those values in a .env file. Then, reference it in your launch.json and use ${env:YOUR_VAR_NAME} in launch.json settings. Here's an example.

//launch.json

{
  "version": "0.2.0",
  "configurations": [
    {
      ...
      "envFile": "${workspaceFolder}/.env",
      "username": "${env:ROKU_USERNAME}",
      "password": "${env:ROKU_PASSWORD}"
      ...
    }
  ]
}
# .env

#the username for the roku
ROKU_USERNAME=rokudev
#the password for the roku
ROKU_PASSWORD=password123

This extension uses the dotenv npm module for parsing the .env files, so see this link for syntax information.

Process environment

The envFile is optional. Any ${env:YOUR_VAR_NAME} reference is resolved against the process environment (the environment VS Code was launched with) as well. When an envFile is provided, its values take precedence over the process environment. If the referenced envFile cannot be found, the extension falls back to the process environment instead of failing the debug session.