mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-10-31 01:45:50 +08:00
[New] install script: Allow installation from other repository
This commit is contained in:
committed by
Jordan Harband
parent
f3fa157456
commit
4e9df33cb7
@@ -1,6 +1,8 @@
|
||||
#!/bin/sh
|
||||
|
||||
setup () {
|
||||
setup() {
|
||||
# Needed to avoid to checkout the repo to the latest nvm version, losing the commits of the current PR
|
||||
unset NVM_DIR
|
||||
shopt -s expand_aliases
|
||||
alias .=':'
|
||||
NVM_ENV=testing \. ../../install.sh > /dev/null
|
||||
@@ -12,7 +14,7 @@ cleanup () {
|
||||
shopt -u expand_aliases
|
||||
}
|
||||
|
||||
die () { echo "$@"; exit 1; }
|
||||
die () { echo "$@"; cleanup; exit 1; }
|
||||
|
||||
setup
|
||||
|
||||
|
||||
Reference in New Issue
Block a user