scripts/gemsets in rvm-0.1.40 vs scripts/gemsets in rvm-0.1.41
- old
+ new
@@ -391,12 +391,12 @@
# Loads the default gemsets for the current interpreter and gemset.
gemset_initial() {
$rvm_scripts_path/log "info" "Importing initial gemsets for $(__rvm_environment_identifier)."
mkdir -p "$rvm_gemsets_path/$(echo "$rvm_ruby_string" | tr '-' '/')" 2>/dev/null
- for gemsets_path in "$rvm_gemsets_path" "$rvm_gemsets_path/$rvm_ruby_interpreter" "$rvm_gemsets_path/$rvm_ruby_interpreter/$rvm_ruby_version" "$rvm_gemsets_path/$rvm_ruby_interpreter/$rvm_ruby_version/$rvm_ruby_patch_level" ; do
- if [[ ! -z "$rvm_gemset_name" ]] ; then
+ for gemsets_path in $(__rvm_ruby_string_paths_under "$rvm_gemsets_path") ; do
+ if [[ -n "$rvm_gemset_name" ]] ; then
if [[ -s "${gemsets_path}/${rvm_gemset_name}.gems" ]] ; then
(source "$rvm_scripts_path/rvm"; rvm gemset import "${gemsets_path}/${rvm_gemset_name}.gems") > /dev/null
fi
else
if [[ -d "$gemsets_path" ]] && [[ -s "${gemsets_path}/default.gems" ]] ; then
@@ -416,10 +416,10 @@
$rvm_scripts_path/log "error" "'gem' was not found, cannot perform gem actions (Do you have an RVM ruby selected?)"
exit 1
fi
action="$(echo $* | awk '{print $1}')"
-gems_args=$(echo "$*" | awk '{$1="" ; print}' | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//')
+gems_args="$(echo "$*" | awk '{$1="" ; print}' | __rvm_strip)"
export rvm_gemset_name
if [[ "import" = "$action" ]] || [[ "load" = "$action" ]] ; then
if [[ -z "$rvm_ruby_strings" ]]; then
gemset_import