NervJS / taro-project-templates

Templates for `taro init`
82 stars 71 forks source link

4.0.0 beta,RN 环境,package.json upgradePeerdeps `ERR spawn pnpm ENOENT` Install Failed 安装失败 #124

Open SolidZORO opened 10 months ago

SolidZORO commented 10 months ago

我是 yarn1 用户,yarn upgradePeerdeps 后出现 ERR spawn pnpm ENOENT。

看了下 https://www.npmjs.com/package/install-peerdeps 才知道原来 -P 是用 pnpm,我电脑没装 pnpm 就报错了。

https://github.com/NervJS/taro-project-templates/blob/55bc21804af5025da0089bff10cce200fa5e9e97/react-native/package.json.tmpl#L35C9-L35C9

"upgradePeerdeps": "install-peerdeps @tarojs/taro-rn@{{ version }} -o -P && install-peerdeps @tarojs/components-rn@{{ version }} -o -P && install-peerdeps @tarojs/router-rn@{{ version }} -o -P && pod-install"

考虑到是 beta,我就不 PR 了,如果需要的话,回头可以匹配一下用户的安装环境。