mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-05-10 22:31:51 +00:00
Remove 'function' to define functions
/bin/sh doesn't like it...
This commit is contained in:
parent
8839515af3
commit
6375e37cee
@ -6,7 +6,7 @@ set -e
|
||||
# Get's the path of the current script calling the function
|
||||
# !! Doesn't check for circular symlinks !!
|
||||
# e.g /tmp/path/to/script.sh
|
||||
function nvm_script_path(){
|
||||
nvm_script_path(){
|
||||
SOURCE=$0
|
||||
while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink
|
||||
DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
|
||||
@ -19,7 +19,7 @@ function nvm_script_path(){
|
||||
}
|
||||
|
||||
# Get the directory of the current script
|
||||
function nvm_script_dir(){
|
||||
nvm_script_dir(){
|
||||
echo "$( dirname $(nvm_script_path))"
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user