Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Bugfix: remove symlink if it exists.

  • Loading branch information...
commit 0d404bd01c1a64dc6930d6a0b36ee8df3d13e230 1 parent 915589b
@wayneeseguin wayneeseguin authored
Showing with 6 additions and 1 deletion.
  1. +6 −1 scripts/selector
View
7 scripts/selector
@@ -424,12 +424,17 @@ __rvm_use()
# Copy wrapper scripts for the newly set default to the RVM bin path.
for wrapper in "$rvm_path"/wrappers/default/* ; do
+
+ if [[ -L "$rvm_bin_path/${wrapper##*\/}" ]] ; then
+ rm -f "$rvm_bin_path/${wrapper##*\/}"
+ fi
+
cp -f "$wrapper" "$rvm_bin_path/${wrapper##*\/}"
# If the RVM bin path is different from rvm_path/bin, ensure they are
# in sync.
if [[ "${rvm_bin_path}" != "${rvm_path}/bin" ]] ; then
- cp -f "${wrapper}" "${rvm_path}/bin"
+ cp -f "${wrapper}" "${rvm_path}/bin/"
fi
done
Please sign in to comment.
Something went wrong with that request. Please try again.