diff --git a/README.md b/README.md index 8a3b70bf..b9f4b49a 100644 --- a/README.md +++ b/README.md @@ -70,7 +70,9 @@ Here are some examples: screen shot 2017-08-08 at 12 53 38 pm screen shot 2017-08-08 at 12 53 25 pm -#### Windows note +#### Windows command prompt notes + +##### CMD On Windows the environment variable is set using the `set` command. @@ -78,14 +80,32 @@ On Windows the environment variable is set using the `set` command. set DEBUG=*,-not_this ``` -Note that PowerShell uses different syntax to set environment variables. +Example: + +```cmd +set DEBUG=* & node app.js +``` + +##### PowerShell (VS Code default) + +PowerShell uses different syntax to set environment variables. ```cmd $env:DEBUG = "*,-not_this" ``` +Example: + +```cmd +$env:DEBUG='app';node app.js +``` + Then, run the program to be debugged as usual. +npm script example: +```js + "windowsDebug": "@powershell -Command $env:DEBUG='*';node app.js", +``` ## Namespace Colors