255 error while running NPX

Asked

Viewed 16 times

-1

I can’t create an React app. I’ve tried npm cache clear --force and tb tried to install it globally, but nothing works. Error log:

pm ERR! code EPERM npm ERR! syscall open npm ERR! path /home/prihscapin/. npm/_cacache/content-v2/sha512/14/21/2143fe2b135cd8bfdad85c9c3f9ac46ab279a58dee631cfea1b9678167bd388d44f2d36739019c96ba3a4c4756b1ea6570f4dc8931fb8ad8230359521f80 npm ERR! Errno -1 npm ERR! npm ERR! Your cache Folder contains root-owned files, due to a bug in npm ERR! Previous versions of npm which has Since been addressed. npm ERR! npm ERR! To permanently fix this problem, Please run: npm ERR! sudo chown -R 1001:1001 "/home/prihscapin/. npm"

npm ERR! A complete log of this run can be found in: npm ERR! /home/prihscapin/. npm/_logs/2021-07-06T15_49_03_565Z-debug.log Installation of [ 'create-React-app@latest' ] failed with code 255

Thank you in advance! :)

1 answer

0

Roda sudo npm ERR! sudo chown -R 1001:1001 "/home/prihscapin/. npm" if it doesn’t work try as well: sudo npx create-React-app my-app.

Or sudo su and then npx.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.