I try to install React Navigation and returns a denied permission error

Asked

Viewed 792 times

0

I tried to install the React Navigation module in my project with the following command:

npm install --save react-navigation

But the following error returns to me:

npm ERR! code 1
npm ERR! Command failed: /usr/bin/git clone -q git://github.com/react-navigation/react-native-tab-view.git /home/diegomng/.npm/_cacache/tmp/git-clone-ad6cfd48
npm ERR! /home/diegomng/.npm/_cacache/tmp/git-clone-ad6cfd48/.git: Permissão negada
npm ERR!

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/diegomng/.npm/_logs/2018-04-03T16_31_55_746Z-debug.log

My version of Nodejs: V9.6.1

NPM: 5.8.0

Yarn: 0.22

React-Native-cli: 2.0.1

React-Native: 0.54.0

  • 1

    Already tried to install using sudo npm install --save react-navigation?

2 answers

1

Your problem is not with React, but with package manager.

Try to use the yarn, I’ve had this problem and with Yarn it’s very quiet.

0

I also had this problem with some React packages. If you’re using your machine’s command terminal, try using the Git terminal.

Install the Git suitable for your OS. After that, you’ll have Git CMD. Through it many errors like this can be avoided.

Browser other questions tagged

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