Skip to content

Commit

Permalink
Create npm
Browse files Browse the repository at this point in the history
  • Loading branch information
Robbilie authored Nov 2, 2024
1 parent 2607bb7 commit add2137
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions bin/npm
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/usr/bin/env bash
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh"

set -e

npm $@

if [ "$1" == "install" ]; then
find $(dirname $(nvm which node)) -executable \( -type f -o -type l \) -print | sed '/node$/d;/npm$/d' | xargs -t -I{} ln -sf {} ~/bin/
fi

0 comments on commit add2137

Please sign in to comment.