mirror of
https://github.com/pyenv/pyenv.git
synced 2025-11-13 22:03:52 -05:00
Use read -a to split output into an array (#1450)
This commit is contained in:
@@ -5,10 +5,9 @@ set -e
|
||||
|
||||
unset RBENV_VERSION_ORIGIN
|
||||
|
||||
OLDIFS="$IFS"
|
||||
IFS=$'\n' scripts=(`rbenv-hooks version-origin`)
|
||||
IFS="$OLDIFS"
|
||||
IFS=$'\n' read -d '' -r -a scripts <<<"$(rbenv-hooks version-origin)" || true
|
||||
for script in "${scripts[@]}"; do
|
||||
# shellcheck disable=SC1090
|
||||
source "$script"
|
||||
done
|
||||
|
||||
|
||||
Reference in New Issue
Block a user