xgqfrms™, xgqfrms® : xgqfrms's offical website of GitHub!

taro & Error: spawn taro ENOENT

https://stackoverflow.com/questions/27688804/how-do-i-debug-error-spawn-enoent-on-node-js

node-cross-spawn

https://github.com/moxystudio/node-cross-spawn





https://github.com/NervJS/taro/issues/1221


bug


solution

https://nervjs.github.io/taro/docs/GETTING-STARTED.html#cli-工具安装

install matched taro cli version

# yarn add package-name@x.x.x

$ yarn global add @tarojs/cli@1.3.34

taro cli

# install latest version
$ yarn global add @tarojs/cli

# install specific version

# $ yarn add package-name@x.x.x
$ yarn global add @tarojs/cli@1.3.34

CLI 工具安装

# 首先,你需要使用 npm 或者 yarn 全局安装@tarojs/cli,或者直接使用npx:

# 使用 npm 安装 CLI
$ npm install -g @tarojs/cli

# 使用 yarn 安装 CLI
$ yarn global add @tarojs/cli


# 注意事项
# 值得一提的是,如果安装过程出现sass相关的安装错误,请在安装mirror-config-china后重试。

$ npm install -g mirror-config-china


原文地址:https://www.cnblogs.com/xgqfrms/p/12551332.html