Taro全局安装的体验不太好,这个可否修复一下? #11001
jun4rui
started this conversation in
Feature Request
Replies: 3 comments 1 reply
-
我翻了以前关闭的这个问题,说的是不用root安装,但是不用root全局是装不上去的。提示新建目录没权限(因为要装在系统目录),root装的也需要root来init新项目,死循环了。 |
Beta Was this translation helpful? Give feedback.
0 replies
-
create-react-app 和 vue-cli 在你的这种权限要求情景下能否正常安装使用呢? |
Beta Was this translation helpful? Give feedback.
1 reply
-
目前来说,Taro在Mac下目录和文件的权限问题,最好最快的办法就是用sudo npm install -g tarojs/cli安装好以后,将templates目录777化 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
用Mac举例一下:
首,全局安装需要
sudo
,权限是root的,这个没问题;但是下一步新建工程了,需要执行taro init myApp,这个也需要
sudo
了,不sudo
就会导致[Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/@tarojs/cli/templates/taro-temp']
错误。但是
sudo
会导致整个工程目录所有权限都是root的,在用户账号下都无法修改。就这样一个问题,新建工程以后还要手工改一下目录所有者,有点膈应,能否处理一下?
Beta Was this translation helpful? Give feedback.
All reactions