Last active
February 7, 2019 14:56
-
-
Save saleh-old/baae07b9c3d38382eeb58d97cefd8d73 to your computer and use it in GitHub Desktop.
Node useful commands that I keep forgetting
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To see where global packages (and which packages) are installed | |
npm list -g | |
# set new path for global packages: | |
mkdir ~/.global-modules | |
# add to ~/.npmrc: | |
npm config set prefix "~/.global-modules" | |
# then load it in ~/.zshrc: | |
export PATH=~/.global-modules/bin:$PATH | |
# nvm set default | |
nvm alias default vx.y.z |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment