Skip to content

Instantly share code, notes, and snippets.

@checktravis
Created June 23, 2018 19:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save checktravis/412a9deb1191fc88870ee41dfdee7565 to your computer and use it in GitHub Desktop.
Save checktravis/412a9deb1191fc88870ee41dfdee7565 to your computer and use it in GitHub Desktop.
fix npm permissions, solve for error "npm WARN checkPermissions Missing write access to /usr/lib/..."

ref. npm/npm#8165 (comment)

mkdir ~/.npm-global
npm config set prefix '~/.npm-global'

vim ~/.profile # add this line:
export PATH=~/.npm-global/bin:$PATH

source ~/.profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment