rvm 0.1.20 → 0.1.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README CHANGED
@@ -26,28 +26,24 @@ Action
26
26
  rake - runs a rake task against specified and/or all rubies
27
27
  tests - runs 'rake test' across selected ruby versions
28
28
  specs - runs 'rake spec' across selected ruby versions
29
+ monitor - Monitor cwd for testing, run `rake {spec,test}` on changes.
29
30
 
30
- gems - gems(ets): http://rvm.beginrescueend.com/gemsets/#managing
31
+ gemset - gemsets: http://rvm.beginrescueend.com/gemsets/
31
32
 
32
- gemdir - switch to gem directory for installation (new login shell)
33
- srcdir - switch to src directory for the current ruby installation
33
+ gemdir - display the path to the current gem directory (GEM_HOME).
34
+ srcdir - display the path to rvm source directory (may be yanked)
34
35
 
35
36
  fetch - Performs an archive / src fetch only of the selected ruby.
36
- srcdir - display the path to rvm source directory (may be yanked)
37
37
  list - show currently installed rubies, interactive output.
38
- rubies - (query info) default, installed, or expand_string <str>
39
- iconv - Install iconv
40
- openssl - Install openssl
41
- ncurses - Install ncurses
42
- zlib - Install zlib
43
- readline - with install, install readline versions 5.2 & 6.0
44
- monitor - Monitor cwd for testing, run `rake {spec,test}` on changes.
38
+ http://rvm.beginrescueend.com/listing/
39
+ package - Install a dependency package {readline,iconv,zlib,openssl}
40
+ http://rvm.beginrescueend.com/packages/
45
41
  notes - Display notes, with operating system specifics.
46
42
 
47
43
  Implementation
48
44
 
49
- * ruby - MRI/YARV Ruby (The Standard), defaults to 1.8.6
50
- jruby - JRuby
45
+ * ruby - MRI/YARV Ruby (The Standard) {1.8.6,1.8.7,1.9.1,1.9.2...}
46
+ jruby - JRuby {1.3.1,1.4.0}
51
47
  rbx - rubinius
52
48
  ree - ruby Enterprise Edition
53
49
  macruby - MacRuby (Mac OS X Only)
@@ -64,7 +60,6 @@ Flags
64
60
  --default - with ruby select, sets a default ruby for new shells.
65
61
  --debug - Toggle debug mode on for very verbose output.
66
62
  --force - Force install, removes old install & source before install.
67
- --all - Used with 'rvm list' to display 'most' available versions.
68
63
  --dump - Used with gemset to dump the current ruby's gemset.
69
64
  --load - Used with gemset to load a specified gemset file
70
65
  --summary - Used with rubydo to print out a summary of the commands run.
data/config/db CHANGED
@@ -34,6 +34,6 @@ maglev_url=http://glass-downloads.gemstone.com/maglev
34
34
  maglev_repo_url=git://github.com/MagLev/maglev.git
35
35
  rubinius_repo_url=git://github.com/evanphx/rubinius.git
36
36
  shyouhei_repo_url=git://github.com/shyouhei/ruby.git
37
- ironruby_version=0.9.3
37
+ ironruby_version=1.0-rc2
38
38
  ironruby_repo_url=git://github.com/ironruby/ironruby.git
39
- ironruby_url=http://cloud.github.com/downloads/nrk/ironruby/
39
+ ironruby_url=http://github.com/ironruby/ironruby/zipball/
data/config/md5 CHANGED
@@ -59,3 +59,4 @@ zlib-1.2.3.tar.gz=debc62758716a169df9f62e6ab2bc634
59
59
  curl-7.19.7.tar.gz=ecb2e37e45c9933e2a963cabe03670ab
60
60
  pkg-config-0.23.tar.gz=d922a88782b64441d06547632fd85744
61
61
  rubygems-1.3.6.tgz=789ca8e9ad1d4d3fe5f0534fcc038a0d
62
+ ironruby-ironruby-c912e86.tar.gz=80708c23577ff9bf557f63f0f716fe26
data/examples/rvmrc CHANGED
@@ -44,7 +44,11 @@
44
44
 
45
45
  # Install On Use Flag
46
46
  # Install rubies when used if are not installed.
47
- #export ruby_install_on_use=1
47
+ #export rvm_install_on_use_flag=1
48
+
49
+ # Gemset Creat on use Flag
50
+ # This will create a gemset when the gemset is used if it does not exist
51
+ # export rvm_gemset_create_on_use_flag=1
48
52
 
49
53
  # Make Flags, I have 8 cpu's so I might use 7 make threads:
50
54
  #export rvm_make_flags="-j7"
data/install CHANGED
@@ -92,7 +92,7 @@ if [[ ! -s "$rvm_config_path/user" ]] ; then
92
92
  echo '# Users settings file, overrides db file settings and persists across installs.' >> $rvm_config_path/user
93
93
  fi
94
94
 
95
- scripts="monitor match log install color db fetch log set libraries"
95
+ scripts="monitor match log install color db fetch log set package"
96
96
  for script_name in $(echo $scripts) ; do
97
97
  chmod +x $rvm_scripts_path/$script_name
98
98
  done
data/lib/VERSION.yml CHANGED
@@ -1,4 +1,4 @@
1
1
  ---
2
2
  :major: 0
3
3
  :minor: 1
4
- :patch: 20
4
+ :patch: 21
data/rvm.gemspec CHANGED
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{rvm}
8
- s.version = "0.1.20"
8
+ s.version = "0.1.21"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Wayne E. Seguin"]
12
- s.date = %q{2010-02-28}
12
+ s.date = %q{2010-03-02}
13
13
  s.default_executable = %q{rvm-install}
14
14
  s.description = %q{Manages Ruby interpreter environments and switching between them.}
15
15
  s.email = %q{wayneeseguin@gmail.com}
@@ -65,7 +65,6 @@ Gem::Specification.new do |s|
65
65
  "scripts/utility",
66
66
  "scripts/version"
67
67
  ]
68
- s.has_rdoc = false
69
68
  s.homepage = %q{http://github.com/wayneeseguin/rvm}
70
69
  s.post_install_message = %q{********************************************************************************
71
70
 
data/scripts/cli CHANGED
@@ -50,30 +50,54 @@ __rvm_parse_args() {
50
50
 
51
51
  gemset)
52
52
  rvm_action=$rvm_token
53
+
54
+ export rvm_ruby_gem_home="$GEM_HOME"
55
+
53
56
  if [[ "clear" = "$1" ]] ; then
54
57
  unset rvm_gemset_name ; shift
55
- export rvm_ruby_gem_home="$(echo $GEM_HOME | sed 's/%.*$//')"
56
- export GEM_HOME="$rvm_ruby_gem_home"
57
- export BUNDLE_PATH="$rvm_ruby_gem_home"
58
- export GEM_PATH="$rvm_ruby_gem_home/bin:$rvm_ruby_gem_home%global/bin"
59
58
  rvm_ruby_args="clear"
60
- rvm_parse_break=1
61
- elif [[ "delete" = "$1" ]] || [[ "use" = "$1" ]] ; then
62
- export rvm_${1}_flag=1
63
- export rvm_ruby_args="$@" ; shift
59
+ elif [[ "use" = "$1" ]] ; then
60
+ rvm_use_flag=1
61
+ rvm_ruby_args="$@" ; shift
62
+ export rvm_use_flag rvm_ruby_args
64
63
  rvm_gemset_name="$1"; shift
65
- export rvm_ruby_string=$(echo $rvm_gemset_name | sed 's/\(.*\)%.*/\1/')
66
- export rvm_gemset_name=$(echo $rvm_gemset_name | sed 's/.*%\(.*\)/\1/')
67
- if [[ "$rvm_ruby_string" != "$rvm_gemset_name" ]] ; then export rvm_ruby_string ; fi
64
+ if [[ ! -z "$(echo $rvm_gemset_name | grep '%')" ]] ; then
65
+ rvm_ruby_string=$(echo $rvm_gemset_name | sed 's/\(.*\)%.*/\1/')
66
+ rvm_gemset_name=$(echo $rvm_gemset_name | sed 's/.*%\(.*\)/\1/')
67
+ if [[ "$rvm_ruby_string" != "$rvm_gemset_name" ]] ; then
68
+ export rvm_ruby_string="$rvm_ruby_string%$rvm_gemset_name"
69
+ else
70
+ unset rvm_ruby_string
71
+ fi
72
+ export rvm_ruby_gem_home="$rvm_ruby_gem_home%$rvm_gemset_name"
73
+ fi
74
+ if [[ ! -z "$rvm_gemset_name" ]] ; then export rvm_gemset_name ; fi
75
+ elif [[ "delete" = "$1" ]] ; then
76
+ rvm_delete_flag=1
77
+ rvm_ruby_args="$@" ; shift
78
+ rvm_gemset_name="$1"; shift
79
+ export rvm_delete_flag rvm_ruby_args rvm_gemset_name
80
+ if [[ ! -z "$(echo $rvm_gemset_name | grep '%')" ]] ; then
81
+ rvm_ruby_string=$(echo $rvm_gemset_name | sed 's/\(.*\)%.*/\1/')
82
+ rvm_gemset_name=$(echo $rvm_gemset_name | sed 's/.*%\(.*\)/\1/')
83
+ if [[ "$rvm_ruby_string" != "$rvm_gemset_name" ]] ; then
84
+ export rvm_ruby_string="$rvm_ruby_string%$rvm_gemset_name"
85
+ else
86
+ unset rvm_ruby_string
87
+ fi
88
+ export rvm_ruby_gem_home="$rvm_ruby_gem_home%$rvm_gemset_name"
89
+ fi
68
90
  if [[ ! -z "$rvm_gemset_name" ]] ; then export rvm_gemset_name ; fi
69
91
  else
70
92
  if [[ -z "$1" ]] ; then
71
93
  rvm_action="error"
72
- rvm_error_message="'gems' must be followed by a gemset action, see http://rvm.beginrescueend.com/gemsets/ for details."
94
+ rvm_error_message="'gemset' must be followed by a gemset action, see http://rvm.beginrescueend.com/gemsets/ for details."
73
95
  else
74
- export rvm_ruby_args="$*" ; export rvm_${1}_flag=1 ; shift
96
+ if [[ "$rvm_ruby_string" != "$rvm_gemset_name" ]] ; then export rvm_ruby_string ; else unset rvm_ruby_string ; fi
97
+ rvm_ruby_args="$@" ; export rvm_ruby_args
75
98
  fi
76
99
  fi
100
+ rvm_parse_break=1
77
101
  ;;
78
102
 
79
103
  gemdir)
@@ -278,7 +302,6 @@ __rvm_parse_args() {
278
302
  --nice) rvm_niceness="$1" ; shift ;;
279
303
  -l|--level) rvm_ruby_patch_level="p$1" ; shift ;;
280
304
  # TODO: handle this below better (if $1 is null)
281
- -m|--gemset) rvm_gemset_name="$1" ; shift ;;
282
305
  --sdk) rvm_sdk="$1" ; shift ;;
283
306
  --archflags) rvm_archflags="$1" ; shift ;;
284
307
  --symlink) rvm_symlink_name="$1" ; shift ;;
@@ -408,14 +431,26 @@ rvm() {
408
431
  result=$?
409
432
  ;;
410
433
  gemset)
434
+ #if $rvm_scripts_path/match $rvm_ruby_args use ; then
411
435
  if [[ "$rvm_use_flag" -eq 1 ]] ; then
412
436
  __rvm_gemset_select
413
- result=$?
414
- if [[ $result -eq 0 ]] ; then
437
+ result=$? ; if [[ $result -eq 0 ]] ; then
415
438
  __rvm_gemset_use
416
439
  fi
417
440
  else
418
441
  $rvm_scripts_path/gemsets $rvm_ruby_args
442
+
443
+ # Clear the gemset.
444
+ if [[ "$rvm_delete_flag" -eq 1 ]] ; then
445
+ gem_prefix="$(echo $GEM_HOME | sed 's/%.*$//')"
446
+ if [[ "$GEM_HOME" = "$gem_prefix%$rvm_gemset_name" ]] ; then
447
+ rvm_ruby_gem_home="$gem_prefix"
448
+ GEM_HOME="$rvm_ruby_gem_home"
449
+ BUNDLE_PATH="$rvm_ruby_gem_home"
450
+ GEM_PATH="$rvm_ruby_gem_home/bin:$rvm_ruby_gem_home%global/bin"
451
+ export rvm_ruby_gem_home GEM_HOME BUNDLE_PATH GEM_PATH
452
+ fi ; unset gem_prefix
453
+ fi
419
454
  fi
420
455
  result=$?
421
456
  ;;
data/scripts/fetch CHANGED
@@ -6,27 +6,35 @@ trap "if [[ -d $rvm_tmp_path/ ]] && [[ -f $rvm_tmp_path/$$ ]] ; then rm -f $rvm_
6
6
 
7
7
  record_md5() {
8
8
  if [[ "Darwin" = "$(uname)" ]] || [[ "FreeBSD" = "$(uname)" ]]; then
9
- archive_md5="$(md5 $archive | awk '{print $NF}')"
9
+ archive_md5="$(/sbin/md5 $archive | awk '{print $NF}')"
10
10
  else
11
11
  archive_md5="$(md5sum $archive | awk '{print $1}')"
12
12
  fi
13
13
  $rvm_scripts_path/db "$rvm_config_path/md5" "$archive" "$archive_md5"
14
14
  }
15
15
 
16
+ builtin cd "$rvm_archives_path"
17
+
18
+ if [[ -z "$1" ]] ; then $rvm_scripts_path/log "fail" "BUG: $0 called without an argument :/" ; exit 1 ; fi
19
+
20
+ url="$1"; download=1 ; package_name="$2"
21
+
16
22
  if ! which curl &> /dev/null; then
17
23
  $rvm_scripts_path/log "fail" "rvm requires curl, which does not seem to exist in your path :("
18
24
  exit 1
19
25
  elif [[ ! -z ${rvm_proxy} ]] ; then
20
- fetch_command="curl -x${rvm_proxy} -O -L --create-dirs -C - " # -s for silent
26
+ fetch_command="curl -x${rvm_proxy} -L --create-dirs -C - " # -s for silent
21
27
  else
22
- fetch_command="curl -O -L --create-dirs -C - " # -s for silent
28
+ fetch_command="curl -L --create-dirs -C - " # -s for silent
23
29
  fi
24
30
 
25
- builtin cd "$rvm_archives_path"
26
-
27
- if [[ -z "$1" ]] ; then $rvm_scripts_path/log "fail" "BUG: $0 called without an argument :/" ; exit 1 ; fi
28
-
29
- archive=$(basename "$1") ; downlaod=1
31
+ if [[ ! -z "$package_name" ]] ; then
32
+ fetch_command="${fetch_command} -o ${package_name} "
33
+ archive="$package_name"
34
+ else
35
+ fetch_command="${fetch_command} -O "
36
+ archive=$(basename "$url")
37
+ fi
30
38
 
31
39
  if [[ ! -z "$rvm_debug_flag" ]] ; then $rvm_scripts_path/log "debug" "Fetching $archive" ; fi
32
40
 
@@ -49,12 +57,12 @@ fi
49
57
 
50
58
  if [[ $download -gt 0 ]] ; then
51
59
  rm -f $archive
52
- eval $fetch_command "$1"
60
+ eval $fetch_command "$url"
53
61
  result=$?
54
62
  if [[ $result -gt 0 ]] ; then
55
63
  retry=0
56
64
  if [[ $result -eq 78 ]] ; then
57
- $rvm_scripts_path/log "error" "The requested url does not exist: '$1'"
65
+ $rvm_scripts_path/log "error" "The requested url does not exist: '$url'"
58
66
  elif [[ $result -eq 18 ]] ; then
59
67
  $rvm_scripts_path/log "error" "Partial file. Only a part of the file was transferred. Removing partial and re-trying."
60
68
  rm -f "$archive"
@@ -68,7 +76,7 @@ if [[ $download -gt 0 ]] ; then
68
76
  fi
69
77
 
70
78
  if [[ $retry -eq 1 ]] ; then
71
- eval $fetch_command "$1"
79
+ eval $fetch_command "$url"
72
80
  result=$?
73
81
  if [[ $result -gt 0 ]] ; then
74
82
  $rvm_scripts_path/log "error" "There was an error, please check $rvm_ruby_log_path/*.error.log"
data/scripts/gemsets CHANGED
@@ -23,9 +23,10 @@ __rvm_gemset_dir() {
23
23
  }
24
24
 
25
25
  __rvm_gemset_create() {
26
+ rvm_ruby_gem_prefix=$(echo $rvm_ruby_gem_home | sed 's/%.*$//')
26
27
  for gemset in $(echo $gems_args) ; do
27
- gem_home="$rvm_ruby_gem_home%${gems_args/ /}"
28
- mkdir -p $gem_home
28
+ gem_home="$rvm_ruby_gem_prefix%${gems_args/ /}"
29
+ mkdir -p $gem_home
29
30
  ln -nfs "$HOME/.gem/cache" "$gem_home/cache"
30
31
  $rvm_scripts_path/log "info" "Gemset '$gemset' created."
31
32
  done ; unset gem_home
@@ -34,7 +35,7 @@ __rvm_gemset_create() {
34
35
  __rvm_gemset_list() {
35
36
  if [[ -z "$rvm_ruby_selected_flag" ]] ; then __rvm_select ; fi
36
37
 
37
- $rvm_scripts_path/log "info" "gems(ets) : for $rvm_ruby_string (found in $rvm_gems_path/)"
38
+ $rvm_scripts_path/log "info" "gemsets : for $rvm_ruby_string (found in $rvm_gems_path/)"
38
39
 
39
40
  if [[ ! -z "$rvm_gems_path" ]] ; then
40
41
  if [[ ! -z $rvm_ruby_string ]] ; then
@@ -68,7 +69,7 @@ __rvm_gemset_delete() {
68
69
  $rvm_scripts_path/log "info" "$gemdir already does not exist."
69
70
  fi ; unset gemdir
70
71
  else
71
- $rvm_scripts_path/log "error" "A gems name must be specified in order to delete a gems."
72
+ $rvm_scripts_path/log "error" "A gemset name must be specified in order to delete a gems."
72
73
  fi
73
74
  }
74
75
 
@@ -78,7 +79,7 @@ __rvm_gemset_empty() {
78
79
  if [[ -d "$gemdir" ]] && [[ "$gemdir" != '/' ]] && [[ ! -z "$rvm_force_flag" ]] ; then
79
80
  cd $gemdir && rm -rf ./bin/* ./doc/* ./gems/* ./specifications/*
80
81
  elif [[ -d "$gemdir" ]] ; then
81
- $rvm_scripts_path/log "warn" "Are you SURE you wish to remove the installed gems for gemset '%$rvm_gemset_name' ($gemdir)?"
82
+ $rvm_scripts_path/log "warn" "Are you SURE you wish to remove the installed gemset for gemset '%$rvm_gemset_name' ($gemdir)?"
82
83
  echo -n "(anything other than 'yes' will cancel) > "
83
84
  read response
84
85
  if [[ "yes" = "$response" ]] ; then
@@ -96,10 +97,10 @@ __rvm_gemset_copy() {
96
97
  source_ruby="$(echo $gems_args | awk '{print $1}')"
97
98
  destination_ruby="$(echo $gems_args | awk '{print $2}')"
98
99
  if [[ -z "$source_ruby" ]] ; then
99
- $rvm_scripts_path/log "error" "Source and destination must be specified: 'rvm gems copy X Y'"
100
+ $rvm_scripts_path/log "error" "Source and destination must be specified: 'rvm gemset copy X Y'"
100
101
  fi
101
102
  if [[ -z "$destination_ruby" ]] ; then
102
- $rvm_scripts_path/log "error" "Source and destination must be specified: 'rvm gems copy X Y'"
103
+ $rvm_scripts_path/log "error" "Source and destination must be specified: 'rvm gemset copy X Y'"
103
104
  fi
104
105
  source_path="$($rvm_bin_path/rvm $source_ruby gem env gemdir | tail -n 1)"
105
106
  destination_path="$($rvm_bin_path/rvm $destination_ruby gem env gemdir | tail -n 1)"
@@ -135,7 +136,7 @@ __rvm_gemset_export() {
135
136
  fi
136
137
  fi
137
138
 
138
- $rvm_scripts_path/log "info" "Exporting current environments gems to $rvm_file_name"
139
+ $rvm_scripts_path/log "info" "Exporting current environments gemset to $rvm_file_name"
139
140
 
140
141
  touch $rvm_file_name
141
142
  echo "# $rvm_file_name generated gem export file. Note that any env variable settings will be missing. Append these after using a ';' field separator" > $rvm_file_name
@@ -318,6 +319,7 @@ fi
318
319
 
319
320
  action="$(echo $* | awk '{print $1}')"
320
321
  gems_args=$(echo "$*" | awk '{$1="" ; print}' | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//')
322
+ export rvm_gemset_name
321
323
 
322
324
  if [[ "import" = "$action" ]] || [[ "load" = "$action" ]] ; then
323
325
  __rvm_gemset_import
@@ -345,7 +347,7 @@ elif [[ "clear" = "$action" ]] ; then
345
347
  $rvm_scripts_path/log "info" "gemset cleared."
346
348
  exit 0
347
349
  else
348
- $rvm_scripts_path/log "error" "Unrecognized gems action '$action'.\n\nValid gems actions are: {create,use,import,export,copy,delete,empty,name,list,gemdir,install}"
350
+ $rvm_scripts_path/log "error" "Unrecognized gemset action '$action'.\n\nValid gems actions are: {create,use,import,export,copy,delete,empty,name,list,gemdir,install}"
349
351
  fi
350
352
 
351
353
  exit $?
data/scripts/install CHANGED
@@ -92,7 +92,7 @@ if [[ ! -s "$rvm_config_path/user" ]] ; then
92
92
  echo '# Users settings file, overrides db file settings and persists across installs.' >> $rvm_config_path/user
93
93
  fi
94
94
 
95
- scripts="monitor match log install color db fetch log set libraries"
95
+ scripts="monitor match log install color db fetch log set package"
96
96
  for script_name in $(echo $scripts) ; do
97
97
  chmod +x $rvm_scripts_path/$script_name
98
98
  done
data/scripts/manage CHANGED
@@ -135,7 +135,7 @@ __rvm_install_ruby() {
135
135
  $rvm_scripts_path/log "error" "There has been an error while trying to fetch the source. Aborting the installation." ; __rvm_pushpop ; return $result
136
136
  fi
137
137
  mv "$rvm_archives_path/macruby_nightly-latest.pkg" "$rvm_archives_path/macruby_nightly.pkg"
138
- __rvm_run "macruby/extract" "sudo installer -pkg '$rvm_archives_path/macruby_nightly.pkg' -target '/'"
138
+ __rvm_run "macruby/extract" "sudo /usr/sbin/installer -pkg '$rvm_archives_path/macruby_nightly.pkg' -target '/'"
139
139
  mkdir -p "$rvm_ruby_home/bin"
140
140
  else
141
141
  macruby_path="/usr/local/bin"
@@ -148,7 +148,7 @@ __rvm_install_ruby() {
148
148
  mkdir -p $rvm_ruby_src_path
149
149
  unzip -o -j "$rvm_archives_path/$rvm_ruby_package_file" "MacRuby 0.5/MacRuby 0.5.pkg" -d "$rvm_ruby_src_path"
150
150
  mv "$rvm_ruby_src_path/MacRuby 0.5.pkg" "$rvm_ruby_src_path/$rvm_ruby_string.pkg"
151
- __rvm_run "macruby/extract" "sudo installer -pkg '$rvm_ruby_src_path/$rvm_ruby_string.pkg' -target '/'"
151
+ __rvm_run "macruby/extract" "sudo /usr/sbin/installer -pkg '$rvm_ruby_src_path/$rvm_ruby_string.pkg' -target '/'"
152
152
  mkdir -p "$rvm_ruby_home/bin"
153
153
  fi
154
154
 
@@ -516,38 +516,42 @@ RubyWrapper
516
516
 
517
517
  __rvm_fetch_ruby
518
518
  if [[ $? -gt 0 ]] ; then result=$? ; return $result ; fi
519
-
520
- builtin cd $rvm_ruby_src_path
521
-
522
- # MONO_LIB=/Library/Frameworks/Mono.framework/Versions/current/lib/
523
- rvm_ruby_make="rake MERLIN_ROOT=\"$rvm_ruby_src_path/Merlin/Main\" compile mono=1 configuration=release --trace"
524
- __rvm_run "rake" "$rvm_ruby_make" "Building IronRuby..."
525
- if [[ $? -gt 0 ]] ; then result=$? ; return $result ; fi
526
-
527
- rm -rf $rvm_ruby_home/*
528
- mkdir -p $rvm_ruby_home/bin $rvm_ruby_home/lib $rvm_ruby_home/lib/ruby $rvm_ruby_home/lib/IronRuby
529
-
530
- cp -r $rvm_ruby_src_path/Merlin/Main/Bin/mono_release/* $rvm_ruby_home/bin/
531
- cp -r $rvm_ruby_src_path/Merlin/Main/Languages/Ruby/Scripts/bin/* $rvm_ruby_home/bin/
532
- cp -r $rvm_ruby_src_path/Merlin/External.LCA_RESTRICTED/Languages/Ruby/redist-libs/ruby/* $rvm_ruby_home/lib/ruby
533
- cp -r $rvm_ruby_src_path/Merlin/Main/Languages/Ruby/Libs/* $rvm_ruby_home/lib/IronRuby
534
519
  else
535
520
  $rvm_scripts_path/log "info" "Retrieving IronRuby"
536
- $rvm_scripts_path/fetch "$rvm_url"
521
+ $rvm_scripts_path/fetch "$rvm_url" "$rvm_ruby_package_file"
537
522
  result=$? ; if [[ "$result" -gt 0 ]] ; then
538
523
  $rvm_scripts_path/log "error" "There has been an error while trying to fetch the source. Aborting the installation." ; __rvm_pushpop ; return $result
539
524
  fi
540
525
 
541
- __rvm_run "extract" "unzip -q -o $rvm_archives_path/$rvm_ruby_package_file ironruby/bin/* ironruby/lib/* -d $rvm_ruby_home" "Extracting $rvm_ruby_package_file ..."
526
+ __rvm_run "extract" "tar zxf $rvm_archives_path/$rvm_ruby_package_file -C $rvm_src_path" "Extracting $rvm_ruby_package_file ..."
542
527
  result=$? ; if [[ "$result" -gt 0 ]] ; then
543
528
  $rvm_scripts_path/log "error" "There has been an error while trying to extract the source. Aborting the installation." ; __rvm_pushpop ; return $result
544
529
  fi
545
530
 
546
- mv $rvm_ruby_home/ironruby/* $rvm_ruby_home
547
- rm -rf $rvm_ruby_home/ironruby
548
- mv $rvm_ruby_home/lib/ironruby $rvm_ruby_home/lib/IronRuby
531
+ rm -rf $rvm_ruby_src_path
532
+ mv $rvm_src_path/$rvm_ruby_package_name $rvm_ruby_src_path
533
+
534
+ #mv $rvm_ruby_home/ironruby/* $rvm_ruby_home
535
+ #rm -rf $rvm_ruby_home/ironruby
536
+ #mv $rvm_ruby_src_path/$rvm_ruby_package_file/* $rvm_ruby_home
537
+ #mv $rvm_ruby_home/lib/ironruby $rvm_ruby_home/lib/IronRuby
549
538
  fi
550
539
 
540
+ builtin cd $rvm_ruby_src_path
541
+
542
+ # MONO_LIB=/Library/Frameworks/Mono.framework/Versions/current/lib/
543
+ rvm_ruby_make="rake MERLIN_ROOT=\"$rvm_ruby_src_path/Merlin/Main\" compile mono=1 configuration=release --trace"
544
+ __rvm_run "rake" "$rvm_ruby_make" "Building IronRuby..."
545
+ if [[ $? -gt 0 ]] ; then result=$? ; return $result ; fi
546
+
547
+ rm -rf $rvm_ruby_home/*
548
+ mkdir -p $rvm_ruby_home/bin $rvm_ruby_home/lib $rvm_ruby_home/lib/ruby $rvm_ruby_home/lib/IronRuby
549
+
550
+ cp -r $rvm_ruby_src_path/Merlin/Main/Bin/mono_release/* $rvm_ruby_home/bin/
551
+ cp -r $rvm_ruby_src_path/Merlin/Main/Languages/Ruby/Scripts/bin/* $rvm_ruby_home/bin/
552
+ cp -r $rvm_ruby_src_path/Merlin/External.LCA_RESTRICTED/Languages/Ruby/redist-libs/ruby/* $rvm_ruby_home/lib/ruby
553
+ cp -r $rvm_ruby_src_path/Merlin/Main/Languages/Ruby/Libs/* $rvm_ruby_home/lib/IronRuby
554
+
551
555
  binaries="gem irb rake rdoc ri ruby"
552
556
  for binary_name in $(echo $binaries); do
553
557
  binary_path=""
data/scripts/rvm-install CHANGED
@@ -92,7 +92,7 @@ if [[ ! -s "$rvm_config_path/user" ]] ; then
92
92
  echo '# Users settings file, overrides db file settings and persists across installs.' >> $rvm_config_path/user
93
93
  fi
94
94
 
95
- scripts="monitor match log install color db fetch log set libraries"
95
+ scripts="monitor match log install color db fetch log set package"
96
96
  for script_name in $(echo $scripts) ; do
97
97
  chmod +x $rvm_scripts_path/$script_name
98
98
  done
data/scripts/selector CHANGED
@@ -104,17 +104,19 @@ __rvm_select() {
104
104
  ironruby)
105
105
  unset rvm_ruby_patch_level
106
106
  if [[ "$rvm_head_flag" -eq 1 ]] ; then
107
- rvm_ruby_version="head"
108
- rvm_ruby_string="${rvm_ruby_interpreter}-${rvm_ruby_version}"
109
- rvm_ruby_package_name="${rvm_ruby_string}"
110
- rvm_ruby_repo_url="${rvm_ruby_repo_url:-$(__rvm_db "ironruby_repo_url")}"
111
- rvm_url="${rvm_ruby_repo_url:-$(__rvm_db "ironruby_repo_url")}"
107
+ export rvm_ruby_version="head"
108
+ export rvm_ruby_string="${rvm_ruby_interpreter}-${rvm_ruby_version}"
109
+ export rvm_ruby_package_name="${rvm_ruby_string}"
110
+ export rvm_ruby_repo_url="${rvm_ruby_repo_url:-$(__rvm_db "ironruby_repo_url")}"
111
+ export rvm_url="${rvm_ruby_repo_url:-$(__rvm_db "ironruby_repo_url")}"
112
112
  else
113
- rvm_ruby_version=${rvm_ruby_version:-"$(__rvm_db "ironruby_version")"}
114
- rvm_ruby_string="${rvm_ruby_interpreter}-${rvm_ruby_version}"
115
- rvm_ruby_package_file="${rvm_ruby_string}.zip"
116
- rvm_ruby_package_name="${rvm_ruby_string}"
117
- rvm_url="$(__rvm_db "ironruby_url")${rvm_ruby_package_file}"
113
+ export rvm_archive_extension="tar.gz"
114
+ export rvm_ruby_version=${rvm_ruby_version:-"$(__rvm_db "ironruby_version")"}
115
+ export rvm_ruby_string="${rvm_ruby_interpreter}-${rvm_ruby_version}"
116
+ sha1=$(curl -s http://github.com/api/v2/yaml/repos/show/ironruby/ironruby/tags | awk '/'${rvm_ruby_version}'/{print $NF}')
117
+ export rvm_ruby_package_file="ironruby-ironruby-${sha1:0:7}.${rvm_archive_extension}"
118
+ export rvm_ruby_package_name="ironruby-ironruby-${sha1:0:7}"
119
+ export rvm_url="$(__rvm_db "ironruby_url")v${rvm_ruby_version}"
118
120
  fi
119
121
  ;;
120
122
 
@@ -194,7 +196,7 @@ __rvm_select() {
194
196
  rvm_minor_version=$(echo $rvm_ruby_version | awk -F'.' '{ print $3 }')
195
197
  fi
196
198
 
197
- rvm_ruby_package_name="$rvm_ruby_string"
199
+ rvm_ruby_package_name="${rvm_ruby_package_name:-$rvm_ruby_string}"
198
200
  rvm_ruby_home="$rvm_rubies_path/$rvm_ruby_string"
199
201
  rvm_ruby_log_path="$rvm_log_path/$rvm_ruby_string"
200
202
  rvm_ruby_src_path="$rvm_src_path/$rvm_ruby_string"
data/scripts/update CHANGED
@@ -92,7 +92,7 @@ if [[ ! -s "$rvm_config_path/user" ]] ; then
92
92
  echo '# Users settings file, overrides db file settings and persists across installs.' >> $rvm_config_path/user
93
93
  fi
94
94
 
95
- scripts="monitor match log install color db fetch log set libraries"
95
+ scripts="monitor match log install color db fetch log set package"
96
96
  for script_name in $(echo $scripts) ; do
97
97
  chmod +x $rvm_scripts_path/$script_name
98
98
  done
data/scripts/utility CHANGED
@@ -409,7 +409,7 @@ __rvm_list_known() {
409
409
  echo -e "ree-1.8.6\nree(-1.8.7) # the default\nree-1.8.6-head\nree-1.8.7-head"
410
410
  echo -e "maglev(-22907)\nmaglev-head"
411
411
  echo -e "mput(-head) # shyouhei head, the default mput"
412
- echo -e "ironruby-0.9.3 # (1.0 RC1)\nironruby-head"
412
+ echo -e "ironruby-0.9.3\nironruby-1.0-rc2\nironruby-head"
413
413
  if [[ "Darwin" = "$(uname)" ]] ; then
414
414
  echo -e "macruby(-nightly) # the default macruby\nmacruby-head # Build from the macruby git repository"
415
415
  fi
@@ -651,12 +651,16 @@ __rvm_gemset_select() {
651
651
  fi
652
652
  if [[ -z "$rvm_gemset_name" ]] ; then unset rvm_gemset_name ; fi
653
653
  else
654
- rvm_ruby_gem_home="$rvm_gems_path/$rvm_ruby_string%$rvm_gemset_name"
654
+ if [[ ! -z "$(echo $rvm_ruby_gem_home | grep '%')" ]] ; then
655
+ rvm_ruby_gem_home="$rvm_gems_path/$rvm_ruby_string%$rvm_gemset_name"
656
+ fi
655
657
  fi
656
658
 
657
659
  # If the gemset does not exist, then notify the user as such and abort the action.
658
- if [[ ! -d "$rvm_ruby_gem_home" ]] && [[ ! -z "$rvm_gemset_name" ]] && [[ -z "$rvm_create_flag" ]]; then
659
- $rvm_scripts_path/log "error" "Gemset '$rvm_gemset_name' does not exist, rvm gems create '$rvm_gemset_name' first."
660
+ if [[ ! -z "$rvm_gemset_name" ]] && [[ ! -d "$rvm_ruby_gem_home%$rvm_gemset_name" ]] && [[ "$rvm_gemset_create_on_use_flag" -ne 1 ]] && [[ "$rvm_create_flag" -ne 1 ]] && [[ "$rvm_delete_flag" -ne 1 ]] ; then
661
+ $rvm_scripts_path/log "error" "Gemset '$rvm_gemset_name' does not exist, rvm gemset create '$rvm_gemset_name' first."
662
+ return 1
663
+ elif [[ "$rvm_delete_flag" -eq 1 ]] ; then
660
664
  return 1
661
665
  fi
662
666
 
@@ -702,22 +706,24 @@ __rvm_gemset_select() {
702
706
 
703
707
  # Use a gemset specified by 'rvm_ruby_gem_home'
704
708
  __rvm_gemset_use() {
705
- if [[ -z "$rvm_ruby_selected_flag" ]] ; then __rvm_select ; fi
706
-
707
709
  if [[ ! -z "$rvm_ruby_gem_home" ]] ; then
708
710
  if [[ ! -d "$rvm_ruby_gem_home" ]] ; then
709
- $rvm_scripts_path/log "error" "Gemset '$rvm_gemset_name' does not exist, rvm gems create '$rvm_gemset_name' first."
710
- return 1
711
+ if [[ "$rvm_gemset_create_on_use_flag" -eq 1 ]] ; then
712
+ $rvm_scripts_path/gemsets create $rvm_gemset_name
713
+ else
714
+ $rvm_scripts_path/log "error" "Gemset '$rvm_gemset_name' does not exist, rvm gemset create '$rvm_gemset_name' first."
715
+ return 1
716
+ fi
711
717
  fi
712
718
 
713
- if [[ "$rvm_interactive" = 1 ]] ; then
714
- $rvm_scripts_path/log "info" "gemset : ${rvm_gemset_name:-default}"
719
+ if [[ "$rvm_interactive" -eq 1 ]] || [[ "$rvm_verbose_flag" -eq 1 ]] ; then
720
+ $rvm_scripts_path/log "info" "Now using gemset '${rvm_gemset_name:-default}'"
715
721
  fi
716
-
717
- export GEM_HOME="$rvm_ruby_gem_home"
718
- export GEM_PATH="$rvm_ruby_gem_path"
719
- export BUNDLE_PATH="$rvm_ruby_gem_home"
720
- __rvm_use
722
+ rvm_ruby_gem_home="$(echo $GEM_HOME | sed 's/%.*$//')%$rvm_gemset_name"
723
+ GEM_HOME="$rvm_ruby_gem_home"
724
+ BUNDLE_PATH="$rvm_ruby_gem_home"
725
+ GEM_PATH="$rvm_ruby_gem_home/bin:$(echo $GEM_HOME | sed 's/%.*$//')%global/bin"
726
+ export rvm_ruby_gem_home GEM_HOME BUNDLE_PATH GEM_PATH
721
727
  fi
722
728
  return 0
723
729
  }
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 1
8
- - 20
9
- version: 0.1.20
8
+ - 21
9
+ version: 0.1.21
10
10
  platform: ruby
11
11
  authors:
12
12
  - Wayne E. Seguin
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-02-28 00:00:00 -05:00
17
+ date: 2010-03-02 00:00:00 -05:00
18
18
  default_executable: rvm-install
19
19
  dependencies: []
20
20
 
@@ -73,7 +73,7 @@ files:
73
73
  - scripts/update
74
74
  - scripts/utility
75
75
  - scripts/version
76
- has_rdoc: false
76
+ has_rdoc: true
77
77
  homepage: http://github.com/wayneeseguin/rvm
78
78
  licenses: []
79
79