From 1a2e11664c72a4a701a96f1fa31f50f812e81152 Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Mon, 10 Feb 2014 20:20:41 +0100 Subject: [PATCH] script to fix failing 'npm update' with brew installed node --- brew | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/brew b/brew index 8d27ea3..65d777b 100755 --- a/brew +++ b/brew @@ -14,4 +14,12 @@ brew install gpg2 brew install mysql brew install imagemagick brew install GraphicsMagick -brew install android \ No newline at end of file +brew install android + +# fix for failing 'npm update' with brew installed node +# reference: https://github.com/Homebrew/homebrew/issues/22408#issuecomment-30812725 +for man in 1 3 5 7; do + ln -sf /usr/local/lib/node_modules/npm/man/man${man}/* /usr/local/share/man/man${man} +done + +ln -sf /usr/local/lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm \ No newline at end of file