Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Permision issue with npm install #984

Closed
Huluti opened this issue Mar 5, 2020 · 11 comments
Closed

[BUG] Permision issue with npm install #984

Huluti opened this issue Mar 5, 2020 · 11 comments

Comments

@Huluti
Copy link

Huluti commented Mar 5, 2020

What steps will reproduce the bug?

npm install

How often does it reproduce? Is there a required condition?

Always.

What is the expected behavior?

installation of the modules.

What do you see instead?

instruction non permisepostinstall: sill install executeActions

image

Aditional details

Already tried to reinstall nodejs, remove the package-lock.json and clean the cache...

@DanielRuf
Copy link

Hi @Huluti,

which npm version do you use?

@Huluti
Copy link
Author

Huluti commented Mar 9, 2020

@DanielRuf Hi! the 6.13.7 version.

@Huluti
Copy link
Author

Huluti commented Mar 9, 2020

I've tried that but it doesn't change the version.
image

@DanielRuf
Copy link

Please check your PATH. Do you also use yarn and maybe some npm version was installed by it or there is some other npm binary loaded before the right one?

@ljharb
Copy link
Contributor

ljharb commented Mar 9, 2020

See that “npm-global” thing? Delete the “prefix” line from your ~/.npmrc

@Huluti
Copy link
Author

Huluti commented Mar 9, 2020

I've this because of this guide.

Without this, I can't install npm globally:

npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user

@ljharb
Copy link
Contributor

ljharb commented Mar 9, 2020

You'd need to use sudo npm install -g to install things globally; separately, you don't install npm, it comes with node - at that point you can use npm to update npm.

@DanielRuf
Copy link

You'd need to use sudo npm install -g to install things globally;

I thought this isn't recommended (anymore) and there were fixes and recommendations to chown it to the current user?

@DanielRuf
Copy link

@ljharb
Copy link
Contributor

ljharb commented Mar 9, 2020

I've seen nothing but problems from the guide linked above; that tweet just says "run sudo chown -R $USER ~/.npm if you do use sudo to install npm globally".

@Huluti
Copy link
Author

Huluti commented Mar 20, 2020

Thank's for your responses. I've remove what the guide said. I have reverted nodejs to 12.16.1 LTS instead of the latest version. And it reworks.

@Huluti Huluti closed this as completed Mar 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants