From ee8e1c1e5334096d58e0d6bca6c006f2ee9c88cb Mon Sep 17 00:00:00 2001 From: Christian Clauss Date: Fri, 11 Jun 2021 06:32:31 +0200 Subject: [PATCH] doc(wiki): If permissions error, please try and then the command. --- Updating-npm's-bundled-node-gyp.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Updating-npm's-bundled-node-gyp.md b/Updating-npm's-bundled-node-gyp.md index 36d36733f0..fcfa59f9eb 100644 --- a/Updating-npm's-bundled-node-gyp.md +++ b/Updating-npm's-bundled-node-gyp.md @@ -16,20 +16,22 @@ We need to start by knowing your version of `npm`: npm --version ``` -## Linux, Mac OS X, Solaris, etc. +## Linux, macOS, Solaris, etc. -Unix is easy. Just run the following command. Use `sudo` if necessary. +Unix is easy. Just run the following command. If your npm is version ___7___, do: ```bash -$ [sudo] npm explore npm/node_modules/@npmcli/run-script -g -- npm_config_global=false npm install node-gyp@latest +$ npm explore npm/node_modules/@npmcli/run-script -g -- npm_config_global=false npm install node-gyp@latest ``` Else if your npm is version ___less than 7___, do: ```bash -$ [sudo] npm explore npm/node_modules/npm-lifecycle -g -- npm install node-gyp@latest +$ npm explore npm/node_modules/npm-lifecycle -g -- npm install node-gyp@latest ``` +If the command fails with a permissions error, please try `sudo` and then the command. + ## Windows Windows is a bit trickier, since `npm` might be installed to the "Program Files" directory, which needs admin privileges in order to