1. Windows finds the directory where nrm is located
C:\Users\username\AppData\Roaming\npm\node_modules\nrm
The cli.js file under the installation path of nrm
2. Open the cli.js file
const NRMRC = path.join(process.env.HOME,'.nrmrc' ); // Change to const NRMRC = path.join(process.env[(process.platform =='win32')?'USERPROFILE': ' HOME'],'.nrmrc');
3. Save it.
nrm ls successfully executed
Similar Posts:
- [Solved] NPM installation Vue scaffold error: npm ERR! Unexpected end of JSON input while parsing near…
- [Solved] NPM downloads the dependency of the front-end Vue admin template master template Error
- After installing nodejs, running NPM – V will cause (module. JS: 339 throw err..) error. Solution
- [Solved] Error reporting of NPM packaged electron app
- Error: exec npm config get prefix ERROR: Command failed: npm config get prefix [How to Solve]
- Two methods to solve the device offline problem of ADB
- uniapp TypeError: Cannot read property ‘replace’ of undefined
- How to Solve ReferenceError: internalBinding is not defined
- [Solved] Cannot run program “git.exe”: CreateProcess error=
- npm install: npm ERR! errno -4048, Error: EPERM: operation not permitted[How to Solve]