npm
패키지를 전역 적으로 설치하려고 npm
하고이 패키지를 /usr/local/lib
폴더에 저장합니다 . 귀하는 user
의 편집 파일을 외부로 권한이없는 home
보안을 위해 디렉토리를.
옵션 1- 사용 중지 npm
및 사용 시작yarn
The issue is connected to npm
so I would stop using it and install yarn
as in their official guide. Packages should be stored inside your home
directory, even when installed globally like the other package manager do (Yarn
, rbenv
etc..), for this and many other reasons I would stop using npm
.
Option 2 - Try to fix npm
There are several solution proposed in this discussion, none of which really good options.
The best option is changing the permission to the folder /usr/local/lib
as explained here
sudo chown -R [owner]:[owner] /usr/local/lib
Then follow the official @vue/cli
installation instructions for either npm
or yarn
Options 3 - Install it via apt package manager
이 패키지의 다른 버전을 사용하는 다른 프로젝트에서 작업 할 수 있으므로 apt 패키지 관리자를 사용하지 않는 것이 좋습니다. 프로젝트 1 이 @vue/cli
버전 1을 사용하는 경우 프로젝트 2 에서 작업하기 위해 업데이트하면 프로젝트 1 이 더 이상 작동하지 않을 수 있습니다.
sudo npm install -g @vue/cli
이 기사는 인터넷에서 수집됩니다. 재 인쇄 할 때 출처를 알려주십시오.
침해가 발생한 경우 연락 주시기 바랍니다[email protected] 삭제
몇 마디 만하겠습니다