“Please try running this command again as Root/Administrator” error when trying to install LESS

后端 未结 11 2072
栀梦
栀梦 2020-12-02 14:09

I\'m trying to install LESS on my machine and have installed node already. However, when I enter \"node install -g less\" I get the following error and am not sure what to d

11条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-02 14:46

    I know this is an old questions but none of the solutions seemed like a good practice hence I am putting how I have solved this issue:

    Tried solving this issue by using Homebrew but it was also installing node in /usr/local directory which would again cause EACCES error.

    Had to use a version manager like nvm for more informations see the official npm guide.

    For various operating system.

    nvm installs node and it's modules in the user's HOME FOLDER thereby solving EACCES issues.

提交回复
热议问题