Skip to content

Commit

Permalink
Check the write permissions of $install_dir (closes #464,#326).
Browse files Browse the repository at this point in the history
  • Loading branch information
postmodern committed Feb 3, 2025
1 parent 88bea94 commit 024a060
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions bin/ruby-install
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ if [[ $no_reinstall -eq 1 ]] && [[ -x "$install_dir/bin/ruby" ]]; then
exit
fi

if ! check_write_permissions "$install_dir"; then
fail "Cannot write to the installation directory: $install_dir"
fi

log "Installing $ruby $ruby_version into $install_dir ..."

pre_install || fail "Pre-install tasks failed!"
Expand Down

0 comments on commit 024a060

Please sign in to comment.