Skip to content

Commit 2d489e7

Browse files
committed
Avoid += for compatibility with older bash versions
1 parent 458d692 commit 2d489e7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

bin/rbenv-install

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ case "$DEFINITION" in
2525
;;
2626
"-k" | "--keep" )
2727
[ -z "${RBENV_BUILD_ROOT}" ] && RBENV_BUILD_ROOT="${RBENV_ROOT}/sources"
28-
RUBY_BUILD_OPTIONS+=" -k"
28+
RUBY_BUILD_OPTIONS="${RUBY_BUILD_OPTIONS} -k"
2929
;;
3030
esac
3131

@@ -35,7 +35,7 @@ PREFIX="${RBENV_ROOT}/versions/${VERSION_NAME}"
3535
# If RBENV_BUILD_ROOT is set, then always pass keep options to ruby-build
3636
if [ -n "${RBENV_BUILD_ROOT}" ]; then
3737
export RUBY_BUILD_BUILD_PATH="${RBENV_BUILD_ROOT}/${VERSION_NAME}"
38-
RUBY_BUILD_OPTIONS+=" -k"
38+
RUBY_BUILD_OPTIONS="${RUBY_BUILD_OPTIONS} -k"
3939
fi
4040

4141
ruby-build "$DEFINITION" "$PREFIX" "$RUBY_BUILD_OPTIONS"

0 commit comments

Comments
 (0)