List all available packages

npm search

To install a package, where foo is the package name

npm install foo

List all packages from a project directory

npm ls

To upgrade npm packages

npm update

Get the path that Node is installed in

npm config get prefix