首页 > 解决方案 > 如何在 shelljs 中获取 microsip 或其他 Windows 终端全局应用程序?

问题描述

比如microsip,我安装了它,我可以在powershell中使用它,就像使用下面的脚本打开microsip

PS G:\yyy>  microsip

但是当我使用 shelljs

const shell = require('shelljs')
shell.exec('microsip')

它会返回错误:

UnhandledPromiseRejectionWarning: ReferenceError: microsip is not defined

标签: windowsshelljs

解决方案


推荐阅读