Skip to content

Commit

Permalink
doc(wiki): If permissions error, please try and then the command.
Browse files Browse the repository at this point in the history
  • Loading branch information
cclauss authored and rvagg committed Jun 23, 2021
1 parent d314854 commit ee8e1c1
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Updating-npm's-bundled-node-gyp.md
Expand Up @@ -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
Expand Down

0 comments on commit ee8e1c1

Please sign in to comment.