
Research
/Security News
Contagious Interview Campaign Escalates With 67 Malicious npm Packages and New Malware Loader
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.
Returns an array of NPM directory paths based on the user's platform and environment.
Returns an array of NPM directory paths based on the user's platform and environment.
Please consider following this project's author, Jon Schlinkert, and consider starring the project to show your :heart: and support.
Install with npm:
$ npm install --save npm-paths
This lib does not include the require.main.paths
in the result array. If you do need the require.main.paths
, use global-paths instead.
const paths = require('./');
console.log(paths());
// specify the CWD to start from
console.log(paths('some/directory'));
Results in something like the following:
Mac
// example was run from the "/Users/jonschlinkert/dev/npm-paths/" directory
[ '/Users/jonschlinkert/dev/npm-paths/node_modules',
'/Users/jonschlinkert/dev/node_modules',
'/Users/jonschlinkert/node_modules',
'/Users/node_modules',
'/node_modules',
'/usr/local/lib/node_modules',
'/usr/lib/node_modules' ]
Windows
// example was run from the "F:\\dev\\npm-paths" directory
[ 'C:\\Users\\SERVER\\AppData\\Roaming\\node_modules\\npm',
'C:\\Program Files\\nodejs\\node_modules',
'F:\\dev\\npm-paths\\node_modules',
'F:\\dev\\node_modules',
'F:\\node_modules' ]
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:
$ npm install && npm test
(This project's readme.md is generated by verb, please don't edit the readme directly. Any changes to the readme must be made in the .verb.md readme template.)
To generate the readme, run the following command:
$ npm install -g verbose/verb#dev verb-generate-readme && verb
You might also be interested in these projects:
Commits | Contributor |
---|---|
13 | jonschlinkert |
2 | loremaps |
1 | doowb |
Jon Schlinkert
Copyright © 2018, Jon Schlinkert. Released under the MIT License.
This file was generated by verb-generate-readme, v0.8.0, on December 15, 2018.
FAQs
Returns an array of NPM directory paths based on the user's platform and environment.
We found that npm-paths demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
/Security News
North Korean threat actors deploy 67 malicious npm packages using the newly discovered XORIndex malware loader.
Security News
Meet Socket at Black Hat & DEF CON 2025 for 1:1s, insider security talks at Allegiant Stadium, and a private dinner with top minds in software supply chain security.
Security News
CAI is a new open source AI framework that automates penetration testing tasks like scanning and exploitation up to 3,600× faster than humans.