【发布时间】:2018-07-18 12:20:27
【问题描述】:
我必须从 VS Code 终端执行以下命令。我正在 Windows 10 机器上运行我的应用程序。
set DEBUG=app & node app.js
当我运行上述命令时,终端会给我以下错误消息。
At line:1 char:15
+ set DEBUG=app & node app.js
+ ~
The ampersand (&) character is not allowed. The & operator is reserved for
future use; wrap an ampersand in double quotation marks
("&") to pass it as part of a string.
+ CategoryInfo : ParserError: (:) [],
ParentContainsErrorRecordException
+ FullyQualifiedErrorId : AmpersandNotAllowed
但是,当我从命令窗口分别运行相同的命令时,它按预期执行。
【问题讨论】:
标签: node.js visual-studio-code