1234567891011121314151617181920212223242526 |
- #!/usr/bin/env bash
- dir="$(dirname "$(dirname "$0")")"
- cli="$dir"/bin/npm-cli.js
- tmp="$cli".tmp
- node="$1"
- if [ "x$node" = "x" ]; then
- node="/usr/bin/env node"
- fi
- node="
- sed -e 1d "$cli" > "$tmp"
- echo "$node" > "$cli"
- cat "$tmp" >> "$cli"
- rm "$tmp"
- chmod ogu+x $cli
|