rvm 0.0.65 → 0.0.66
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 +84 -1
- data/install +2 -0
- data/lib/VERSION.yml +1 -1
- data/rvm.gemspec +4 -2
- data/scripts/cli +1 -93
- data/scripts/gems +17 -4
- data/scripts/install +2 -0
- data/scripts/irbrc +9 -0
- data/scripts/irbrc.rb +31 -0
- data/scripts/rvm-install +2 -0
- data/scripts/selector +9 -4
- data/scripts/update +2 -0
- data/scripts/utility +9 -30
- metadata +4 -2
data/README
CHANGED
@@ -1,4 +1,87 @@
|
|
1
|
-
|
1
|
+
|
2
|
+
Usage
|
3
|
+
|
4
|
+
rvm Action [Implementation] [Flags] [Options]
|
5
|
+
|
6
|
+
Action
|
7
|
+
|
8
|
+
* usage - show this usage information
|
9
|
+
use - setup current shell to use a specific ruby version
|
10
|
+
info - show information for current ruby
|
11
|
+
list - show currently installed versions
|
12
|
+
reload - reload rvm source itself (useful after changing rvm source)
|
13
|
+
implode - removes all ruby installations it manages, everything in ~/.rvm
|
14
|
+
update - upgrades rvm to the latest version.
|
15
|
+
reset - remove default and current settings, exit the shell.
|
16
|
+
(If you experience odd behavior try this first)
|
17
|
+
debug - emit environment & configuration information for *current* ruby
|
18
|
+
|
19
|
+
install - install one or many ruby versions
|
20
|
+
uninstall - uninstall one or many ruby versions, leaves their sources
|
21
|
+
remove - uninstall one or many ruby versions and remove their sources
|
22
|
+
|
23
|
+
ruby - runs a named ruby file against specified and/or all rubies
|
24
|
+
gem - runs a gem command using selected ruby's 'gem'
|
25
|
+
rake - runs a rake task against specified and/or all rubies
|
26
|
+
tests - runs 'rake test' across selected ruby versions
|
27
|
+
specs - runs 'rake spec' across selected ruby versions
|
28
|
+
|
29
|
+
gemsync - sync gems from a specified version to current version
|
30
|
+
gemdir - switch to gem directory for installation (new login shell)
|
31
|
+
srcdir - switch to src directory for the current ruby installation
|
32
|
+
|
33
|
+
Implementation
|
34
|
+
|
35
|
+
* ruby - MRI/YARV Ruby (The Standard), defaults to 1.8.6
|
36
|
+
jruby - jRuby
|
37
|
+
rbx - rubinius
|
38
|
+
ree - ruby Enterprise Edition
|
39
|
+
mput - shyouhei(mput)'s github repository
|
40
|
+
system - use the system ruby (eg. pre-rvm state)
|
41
|
+
default - use rvm set default ruby and system if it hasn't been set.
|
42
|
+
|
43
|
+
Flags
|
44
|
+
|
45
|
+
--self - with update, updates rvm itself
|
46
|
+
--rubygems - with update, updates rubygems for selected ruby
|
47
|
+
--default - with ruby select, sets a default ruby for new shells.
|
48
|
+
--debug - Toggle debug mode on for very verbose output.
|
49
|
+
--force - Force install, removes old install & source before install.
|
50
|
+
--all - Used with 'rvm list' to display 'most' available versions.
|
51
|
+
--dump - Used with gemset to dump the current ruby's gemset.
|
52
|
+
--load - Used with gemset to load a specified gemset file
|
53
|
+
--summary - Used with rubydo to print out a summary of the commands run.
|
54
|
+
--jit - Used with rubinius install to build with JIT
|
55
|
+
--latest - with gemset --dump skips version strings for latest gem.
|
56
|
+
--reconfigure - Force ./configure on install even if Makefile already exists.
|
57
|
+
|
58
|
+
Options
|
59
|
+
|
60
|
+
-v|--version - Emit rvm version loaded for current shell
|
61
|
+
-h|--help - Emit this output and exit
|
62
|
+
-l|--level - patch level to use with rvm use / install
|
63
|
+
--tag - subersion tag to use
|
64
|
+
--rev - repository revision # to use or 'head' for
|
65
|
+
|
66
|
+
--prefix - path for all rvm files (~/.rvm/), with trailing slash!
|
67
|
+
--bin - path for binaries to be placed (~/.rvm/bin/)
|
68
|
+
--source - src directory to use (~/.rvm/src/)
|
69
|
+
--archives - directory for downladed files (~/.rvm/archives/)
|
70
|
+
-S - Specify a script file to attempt to load and run (rubydo)
|
71
|
+
-e - Execute code from the command line.
|
72
|
+
-G|--gems - root gem path to use
|
73
|
+
-C|--configure - custom configure options, comma separated
|
74
|
+
default: --enable-shared=true
|
75
|
+
--reconfigure - Force installer to re-run configure if already run
|
76
|
+
--make - custom make command
|
77
|
+
--make-install - custom make install command
|
78
|
+
--nice - process niceness (for slow computers, default 0)
|
79
|
+
-m|--gem-set - use a named gem set, instead of the default set.
|
80
|
+
--rm-gem-set - Remove a named gem set
|
81
|
+
--ree-options - Options passed directly to ree's './installer' on the command line.
|
82
|
+
|
83
|
+
Resources:
|
2
84
|
|
3
85
|
http://rvm.beginrescueend.com/
|
86
|
+
https://www.pivotaltracker.com/projects/26822
|
4
87
|
|
data/install
CHANGED
@@ -32,6 +32,8 @@ for file_name in rvm-prompt gemsync ; do
|
|
32
32
|
chmod +x $rvm_path/bin/$file_name
|
33
33
|
done ; unset file_name
|
34
34
|
|
35
|
+
cp -f $source_dir/README $rvm_path/
|
36
|
+
|
35
37
|
if [[ -z "$rvm_loaded_flag" ]] ; then
|
36
38
|
for rcfile in .bash_profile .bashrc .zshrc ; do
|
37
39
|
if [[ ! -e ~/$rcfile ]] ; then touch ~/$rcfile ; fi
|
data/lib/VERSION.yml
CHANGED
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.0.
|
8
|
+
s.version = "0.0.66"
|
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{2009-10-
|
12
|
+
s.date = %q{2009-10-29}
|
13
13
|
s.default_executable = %q{rvm-install}
|
14
14
|
s.description = %q{Manages Ruby interpreter installations and switching between them.}
|
15
15
|
s.email = %q{wayneeseguin@gmail.com}
|
@@ -35,6 +35,8 @@ Gem::Specification.new do |s|
|
|
35
35
|
"scripts/gems",
|
36
36
|
"scripts/gemsync",
|
37
37
|
"scripts/install",
|
38
|
+
"scripts/irbrc",
|
39
|
+
"scripts/irbrc.rb",
|
38
40
|
"scripts/ruby-installer",
|
39
41
|
"scripts/rvm",
|
40
42
|
"scripts/rvm-install",
|
data/scripts/cli
CHANGED
@@ -9,99 +9,7 @@ function __rvm_meta {
|
|
9
9
|
|
10
10
|
function __rvm_version { __rvm_meta ; echo "rvm ${rvm_meta_version} by ${rvm_meta_author} (${rvm_meta_author_email}) [${rvm_meta_website}]" ; }
|
11
11
|
|
12
|
-
function __rvm_usage {
|
13
|
-
|
14
|
-
echo -e "
|
15
|
-
$(__rvm_version)
|
16
|
-
|
17
|
-
Usage
|
18
|
-
|
19
|
-
rvm Action [Implementation] [Flags] [Options]
|
20
|
-
|
21
|
-
Action
|
22
|
-
|
23
|
-
* usage - show this usage information
|
24
|
-
use - setup current shell to use a specific ruby version
|
25
|
-
info - show information for current ruby
|
26
|
-
list - show currently installed versions
|
27
|
-
reload - reload rvm source itself (useful after changing rvm source)
|
28
|
-
implode - removes all ruby installations it manages, everything in ~/.rvm
|
29
|
-
update - upgrades rvm to the latest version.
|
30
|
-
reset - remove default and current settings, exit the shell.
|
31
|
-
(If you experience odd behavior try this first)
|
32
|
-
debug - emit environment & configuration information for *current* ruby
|
33
|
-
|
34
|
-
install - install one or many ruby versions
|
35
|
-
uninstall - uninstall one or many ruby versions, leaves their sources
|
36
|
-
remove - uninstall one or many ruby versions and remove their sources
|
37
|
-
|
38
|
-
ruby - runs a named ruby file against specified and/or all rubies
|
39
|
-
gem - runs a gem command using selected ruby's 'gem'
|
40
|
-
rake - runs a rake task against specified and/or all rubies
|
41
|
-
tests - runs 'rake test' across selected ruby versions
|
42
|
-
specs - runs 'rake spec' across selected ruby versions
|
43
|
-
|
44
|
-
gemsync - sync gems from a specified version to current version
|
45
|
-
gemdir - switch to gem directory for installation (new login shell)
|
46
|
-
srcdir - switch to src directory for the current ruby installation
|
47
|
-
|
48
|
-
Implementation
|
49
|
-
|
50
|
-
* ruby - MRI/YARV Ruby (The Standard), defaults to 1.8.6
|
51
|
-
jruby - jRuby
|
52
|
-
rbx - rubinius
|
53
|
-
ree - ruby Enterprise Edition
|
54
|
-
mput - shyouhei(mput)'s github repository
|
55
|
-
system - use the system ruby (eg. pre-rvm state)
|
56
|
-
default - use rvm set default ruby and system if it hasn't been set.
|
57
|
-
|
58
|
-
Flags
|
59
|
-
|
60
|
-
--self - with update, updates rvm itself
|
61
|
-
--rubygems - with update, updates rubygems for selected ruby
|
62
|
-
--default - with ruby select, sets a default ruby for new shells.
|
63
|
-
--debug - Toggle debug mode on for very verbose output.
|
64
|
-
--force - Force install, removes old install & source before install.
|
65
|
-
--all - Used with 'rvm list' to display 'most' available versions.
|
66
|
-
--dump - Used with gemset to dump the current ruby's gemset.
|
67
|
-
--load - Used with gemset to load a specified gemset file
|
68
|
-
--summary - Used with rubydo to print out a summary of the commands run.
|
69
|
-
--jit - Used with rubinius install to build with JIT
|
70
|
-
--latest - with gemset --dump skips version strings for latest gem.
|
71
|
-
--reconfigure - Force ./configure on install even if Makefile already exists.
|
72
|
-
|
73
|
-
Options
|
74
|
-
|
75
|
-
-v|--version - Emit rvm version loaded for current shell
|
76
|
-
-h|--help - Emit this output and exit
|
77
|
-
-l|--level - patch level to use with rvm use / install
|
78
|
-
--tag - subersion tag to use
|
79
|
-
--rev - repository revision # to use or 'head' for
|
80
|
-
|
81
|
-
--prefix - path for all rvm files (~/.rvm/), with trailing slash!
|
82
|
-
--bin - path for binaries to be placed (~/.rvm/bin/)
|
83
|
-
--source - src directory to use (~/.rvm/src/)
|
84
|
-
--archives - directory for downladed files (~/.rvm/archives/)
|
85
|
-
-S - Specify a script file to attempt to load and run (rubydo)
|
86
|
-
-e - Execute code from the command line.
|
87
|
-
-G|--gems - root gem path to use
|
88
|
-
-C|--configure - custom configure options, comma separated
|
89
|
-
default: --enable-shared=true
|
90
|
-
--reconfigure - Force installer to re-run configure if already run
|
91
|
-
--make - custom make command
|
92
|
-
--make-install - custom make install command
|
93
|
-
--nice - process niceness (for slow computers, default 0)
|
94
|
-
-m|--gem-set - use a named gem set, instead of the default set.
|
95
|
-
--rm-gem-set - Remove a named gem set
|
96
|
-
--ree-options - Options passed directly to ree's './installer' on the command line.
|
97
|
-
|
98
|
-
Resources:
|
99
|
-
|
100
|
-
http://rvm.beginrescueend.com/
|
101
|
-
https://www.pivotaltracker.com/projects/26822
|
102
|
-
|
103
|
-
" | ${PAGER:-less}
|
104
|
-
}
|
12
|
+
function __rvm_usage { cat "$rvm_path/README" | ${PAGER:-less} ; }
|
105
13
|
|
106
14
|
function __rvm_parse_args {
|
107
15
|
while [[ $# -gt 0 ]] ; do
|
data/scripts/gems
CHANGED
@@ -148,11 +148,14 @@ __rvm_gems_load() {
|
|
148
148
|
fi
|
149
149
|
fi
|
150
150
|
|
151
|
+
mkdir -p "$rvm_gem_path/cache"
|
152
|
+
|
151
153
|
if [[ -f "$rvm_file_name" ]] ; then
|
152
154
|
echo "Loading $rvm_file_name file..."
|
153
155
|
rvm_ruby_gem_list=$(/bin/ls $rvm_ruby_gem_home/specifications/ 2> /dev/null | sed 's#.gems.*$##' 2> /dev/null)
|
156
|
+
|
154
157
|
while read line
|
155
|
-
do # Keep this on 2nd line :(
|
158
|
+
do # Keep this on 2nd line :(
|
156
159
|
# TODO: Switch to a different field separator than ; to allow for evals
|
157
160
|
gem="$(echo $line | awk -F';' '{print $1}')"
|
158
161
|
gem_prefix="$(echo $line | awk -F';' '{print $2}')"
|
@@ -177,11 +180,21 @@ __rvm_gems_load() {
|
|
177
180
|
gem_file_name="${gem_name/ /}-${gem_version/ /}.gem"
|
178
181
|
fi
|
179
182
|
|
180
|
-
if [[ -z "$rvm_force_flag" ]] && [[ -f "${rvm_ruby_gem_home}/specifications/${
|
183
|
+
if [[ -z "$rvm_force_flag" ]] && [[ -f "${rvm_ruby_gem_home}/specifications/${gem_file_name}" ]] ; then
|
181
184
|
unset gem
|
182
185
|
__rvm_log "warn" "$(__color "yellow")$gem_name $gem_version$(__color "none") exists, skipping (--force to re-install)"
|
183
186
|
else
|
184
|
-
|
187
|
+
set -x
|
188
|
+
if [[ -f "$rvm_gem_path/cache/${gem_file_name}" ]] ; then
|
189
|
+
cache_file="$rvm_gem_path/cache/${gem_file_name}"
|
190
|
+
else
|
191
|
+
cache_file="${cache_file:-$(/bin/ls -t "${rvm_gem_path}/*/*/cache/${gem_file_name}*" 2> /dev/null | head -n1)}"
|
192
|
+
if [[ -f "$cache_file" ]] ; then
|
193
|
+
cp "$cache_file" "$rvm_gem_path/cache/$(basename "$cache_file")"
|
194
|
+
fi
|
195
|
+
fi
|
196
|
+
set +x
|
197
|
+
|
185
198
|
if [[ -z "$cache_file" ]] ; then
|
186
199
|
if [[ -f "$gem_file_name" ]] ; then
|
187
200
|
gem="$gem_file_name"
|
@@ -193,10 +206,10 @@ __rvm_gems_load() {
|
|
193
206
|
else # cached
|
194
207
|
gem_file_name="$(basename "$cache_file")"
|
195
208
|
gem_string="$(echo "$gem_file_name" | sed 's#\.gem$##')"
|
209
|
+
|
196
210
|
# TODO: Switch this to use match
|
197
211
|
if [[ ! -z "$(echo "$rvm_ruby_gem_list" | awk "/${gem_name/ /} \(.*$gem_version/{print}")" ]] ; then
|
198
212
|
if [[ ! -z "$rvm_force_flag" ]] ; then
|
199
|
-
cp $cache_file $rvm_temp_path/$gem_file_name
|
200
213
|
gem="$rvm_temp_path/$gem_file_name" # install as a named local gem
|
201
214
|
fi
|
202
215
|
else
|
data/scripts/install
CHANGED
@@ -32,6 +32,8 @@ for file_name in rvm-prompt gemsync ; do
|
|
32
32
|
chmod +x $rvm_path/bin/$file_name
|
33
33
|
done ; unset file_name
|
34
34
|
|
35
|
+
cp -f $source_dir/README $rvm_path/
|
36
|
+
|
35
37
|
if [[ -z "$rvm_loaded_flag" ]] ; then
|
36
38
|
for rcfile in .bash_profile .bashrc .zshrc ; do
|
37
39
|
if [[ ! -e ~/$rcfile ]] ; then touch ~/$rcfile ; fi
|
data/scripts/irbrc
ADDED
@@ -0,0 +1,9 @@
|
|
1
|
+
|
2
|
+
# This loads some niceties for irb, courtesy of rvm.
|
3
|
+
# It also loads your custom ~/.irbrc if it exists.
|
4
|
+
# If you want to customize the irbrc for ONLY this version of
|
5
|
+
# ruby then edit this file. It will only be deleted if you do
|
6
|
+
# an "rvm install" over this ruby version.
|
7
|
+
|
8
|
+
require File.join(ENV["HOME"], ".rvm", "scripts", "irbrc")
|
9
|
+
|
data/scripts/irbrc.rb
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# This is the common irbrc file used by all rvm ruby installations.
|
2
|
+
# This file will be overriden every time you update rvm.
|
3
|
+
|
4
|
+
# Turn on completion.
|
5
|
+
require "irb/completion" rescue nil
|
6
|
+
|
7
|
+
# Turn on history saving.
|
8
|
+
require "irb/ext/save-history"
|
9
|
+
IRB.conf[:HISTORY_FILE] = File.join(ENV["HOME"], ".irb-history")
|
10
|
+
|
11
|
+
# Calculate the ruby string.
|
12
|
+
rvm_ruby_string = ENV["rvm_ruby_string"] || "#{RUBY_ENGINE}-#{RUBY_VERSION}-#{(RUBY_PATCHLEVEL) ? "p#{RUBY_PATCHLEVEL}" : "r#{RUBY_REVISION}"}"
|
13
|
+
|
14
|
+
# Set up the prompt to be RVM specific.
|
15
|
+
@prompt = {
|
16
|
+
:PROMPT_I => "#{rvm_ruby_string} > ", # default prompt
|
17
|
+
:PROMPT_S => "#{rvm_ruby_string}%l> ", # known continuation
|
18
|
+
:PROMPT_C => "#{rvm_ruby_string} > ",
|
19
|
+
:PROMPT_N => "#{rvm_ruby_string} ?> ", # unknown continuation
|
20
|
+
:RETURN => " => %s \n",
|
21
|
+
:AUTO_INDENT => true
|
22
|
+
}
|
23
|
+
IRB.conf[:PROMPT][:RVM] = @prompt
|
24
|
+
IRB.conf[:PROMPT_MODE] = :RVM
|
25
|
+
|
26
|
+
# Load the user's irbrc file, if possible.
|
27
|
+
if File.exists?("#{ENV["HOME"]}/.irbrc_disabled")
|
28
|
+
load File.join(ENV["HOME"], ".irbrc") rescue nil
|
29
|
+
end
|
30
|
+
|
31
|
+
# EOF
|
data/scripts/rvm-install
CHANGED
@@ -32,6 +32,8 @@ for file_name in rvm-prompt gemsync ; do
|
|
32
32
|
chmod +x $rvm_path/bin/$file_name
|
33
33
|
done ; unset file_name
|
34
34
|
|
35
|
+
cp -f $source_dir/README $rvm_path/
|
36
|
+
|
35
37
|
if [[ -z "$rvm_loaded_flag" ]] ; then
|
36
38
|
for rcfile in .bash_profile .bashrc .zshrc ; do
|
37
39
|
if [[ ! -e ~/$rcfile ]] ; then touch ~/$rcfile ; fi
|
data/scripts/selector
CHANGED
@@ -240,7 +240,7 @@ function __rvm_use {
|
|
240
240
|
if [[ ! -z "$rvm_dump_flag" ]] ; then __rvm_gems_dump ; fi
|
241
241
|
}
|
242
242
|
|
243
|
-
|
243
|
+
__rvm_ruby_string() {
|
244
244
|
if [[ ! -z "$rvm_ruby_string" ]] ; then
|
245
245
|
if [[ "system" = "$rvm_ruby_string" ]] ; then
|
246
246
|
__rvm_unset_ruby_variables
|
@@ -260,7 +260,7 @@ function __rvm_ruby_string {
|
|
260
260
|
|
261
261
|
if [[ "$rvm_ruby_version" != "head" ]] ; then
|
262
262
|
patch_level=$(echo $ruby_string | awk -F'-' '{print $3}')
|
263
|
-
if [[ ! -z "$patch_level" ]] ; then rvm_ruby_patch_level="$patch_level" ; fi
|
263
|
+
if [[ ! -z "$patch_level" ]] ; then rvm_ruby_patch_level="p$patch_level" ; fi
|
264
264
|
else
|
265
265
|
unset rvm_ruby_version
|
266
266
|
rvm_head_flag=1
|
@@ -299,9 +299,12 @@ function __rvm_ruby_string {
|
|
299
299
|
if [[ "rbx" = "$rvm_ruby_interpreter" ]] ; then unset rvm_ruby_patch_level ; fi
|
300
300
|
if [[ "mput" = "$rvm_ruby_interpreter" ]] ; then unset rvm_ruby_patch_level ; fi
|
301
301
|
else
|
302
|
-
revision=$(echo $ruby_string | awk -F'-' '{print $
|
302
|
+
revision=$(echo $ruby_string | awk -F'-' '{print $NF}')
|
303
|
+
if [[ ! -z "$revision" ]] ; then rvm_ruby_patch_level="${rvm_ruby_patch_level:-p${patch_level}}" ; fi
|
303
304
|
if [[ ! -z "$revision" ]] ; then
|
304
|
-
if match "$revision" "^
|
305
|
+
if match "$revision" "^[0-9]\.[0-9]" ; then
|
306
|
+
unset rvm_ruby_revision rvm_ruby_tag
|
307
|
+
elif match "$revision" "^p" ; then
|
305
308
|
rvm_ruby_patch_level="$revision"
|
306
309
|
# if [[ "preview" == "$revision" ]] ; then
|
307
310
|
elif match "$revision" "^[0-9]" ; then
|
@@ -312,8 +315,10 @@ function __rvm_ruby_string {
|
|
312
315
|
rvm_ruby_revision="r$revision"
|
313
316
|
fi
|
314
317
|
elif match "$revision" "^r" ; then
|
318
|
+
unset rvm_ruby_patch_level
|
315
319
|
rvm_ruby_revision="$revision"
|
316
320
|
elif match "$revision" "^t" ; then
|
321
|
+
unset rvm_ruby_patch_level rvm_ruby_revision
|
317
322
|
rvm_ruby_tag="$revision"
|
318
323
|
else
|
319
324
|
unset rvm_ruby_patch_level rvm_ruby_revision rvm_ruby_tag
|
data/scripts/update
CHANGED
@@ -32,6 +32,8 @@ for file_name in rvm-prompt gemsync ; do
|
|
32
32
|
chmod +x $rvm_path/bin/$file_name
|
33
33
|
done ; unset file_name
|
34
34
|
|
35
|
+
cp -f $source_dir/README $rvm_path/
|
36
|
+
|
35
37
|
if [[ -z "$rvm_loaded_flag" ]] ; then
|
36
38
|
for rcfile in .bash_profile .bashrc .zshrc ; do
|
37
39
|
if [[ ! -e ~/$rcfile ]] ; then touch ~/$rcfile ; fi
|
data/scripts/utility
CHANGED
@@ -122,12 +122,12 @@ function __rvm_run {
|
|
122
122
|
unset log_file command
|
123
123
|
}
|
124
124
|
|
125
|
-
|
125
|
+
__rvm_cleanup_variables() {
|
126
126
|
__rvm_unset_ruby_variables
|
127
|
-
unset rvm_ruby_selected_flag rvm_action rvm_irbrc_file rvm_src_path rvm_path rvm_prefix_path rvm_gem_path rvm_command rvm_error_message rvm_gem_set_name rvm_url rvm_config_path rvm_bin_path rvm_force_flag rvm_all_flag rvm_reconfigure_flag rvm_make_flags rvm_bin_flag rvm_load_flag rvm_dump_flag rvm_self_flag rvm_gem_flag rvm_rubygems_flag rvm_debug_flag rvm_delete_flag rvm_summary_flag rvm_test_flag _rvm_spec_flag rvm_json_flag rvm_yaml_flag rvm_shebang_flag rvm_env_flag rvm_tail_flag rvm_use_flag rvm_dir_flag rvm_list_flag rvm_empty_flag rvm_log_path rvm_file_name rvm_ruby_configure
|
127
|
+
unset rvm_ruby_selected_flag rvm_action rvm_irbrc_file rvm_src_path rvm_path rvm_prefix_path rvm_gem_path rvm_command rvm_error_message rvm_gem_set_name rvm_url rvm_config_path rvm_bin_path rvm_force_flag rvm_all_flag rvm_reconfigure_flag rvm_make_flags rvm_bin_flag rvm_load_flag rvm_dump_flag rvm_self_flag rvm_gem_flag rvm_rubygems_flag rvm_debug_flag rvm_delete_flag rvm_summary_flag rvm_test_flag _rvm_spec_flag rvm_json_flag rvm_yaml_flag rvm_shebang_flag rvm_env_flag rvm_tail_flag rvm_use_flag rvm_dir_flag rvm_list_flag rvm_empty_flag rvm_log_path rvm_file_name rvm_ruby_configure rvm_benchmark_flag
|
128
128
|
}
|
129
129
|
|
130
|
-
|
130
|
+
__rvm_unset_ruby_variables() {
|
131
131
|
unset rvm_ruby_interpreter rvm_ruby_version rvm_ruby_repo_url rvm_ruby_package_name rvm_ruby_patch_level rvm_ruby_make rvm_ruby_make_install rvm_ruby_revision rvm_ruby_tag rvm_major_version rvm_minor_version rvm_ruby_gem_home rvm_ruby_binary rvm_ruby_home rvm_ruby_log_path rvm_ruby_src_path rvm_ruby_irbrc rvm_ruby_selected_flag rvm_ruby_string rvm_ruby_string rvm_ruby_src_path rvm_ruby_repo_url rvm_major_version rvm_minor_version rvm_ruby_gem_home rvm_head_flag
|
132
132
|
}
|
133
133
|
|
@@ -562,11 +562,12 @@ __rvm_ruby_do() {
|
|
562
562
|
binary="$(echo $rvm_action | sed 's#do$##')"
|
563
563
|
if [[ -x "$rvm_ruby_home/bin/$binary" ]] ; then
|
564
564
|
load_path="$rvm_ruby_home/bin:$rvm_ruby_load_path"
|
565
|
-
|
565
|
+
# TODO: the else case below should be run if $rvm_ruby_args =~ /\.rb$/
|
566
|
+
if [[ "ruby" = "$binary" ]] && [[ "$rvm_benchmark_flag" -ne 1 ]] ; then
|
566
567
|
if match "$rvm_ruby_args" "\.rb$" ; then
|
567
568
|
if [[ -z "$prefix" ]] ; then prefix="-S" ; fi
|
568
569
|
if ! match "$rvm_ruby_args" "$prefix" ; then
|
569
|
-
rvm_ruby_args="$prefix $rvm_ruby_args"
|
570
|
+
rvm_ruby_args="$prefix '$rvm_ruby_args'"
|
570
571
|
fi
|
571
572
|
fi
|
572
573
|
rvm_command="$rvm_ruby_home/bin/$binary $rvm_ruby_require -I$load_path $rvm_ruby_args"
|
@@ -693,38 +694,16 @@ function __rvm_benchmark {
|
|
693
694
|
cat $rvm_ruby_file >> "$rvm_temp_path/$$.rb"
|
694
695
|
echo -e "\n end \nend\n" >> "$rvm_temp_path/$$.rb"
|
695
696
|
rvm_ruby_args="$rvm_temp_path/$$.rb"
|
697
|
+
rvm_benchmark_flag=1
|
696
698
|
rvm_action="ruby"
|
697
699
|
if [[ ! -z "$rvm_debug_flag" ]] ; then echo -e "$rvm_temp_path/$$.rb:\n$(cat $rvm_temp_path/$$.rb)" ; fi
|
698
700
|
__rvm_do
|
699
701
|
}
|
700
702
|
|
701
703
|
function __rvm_irbrc {
|
704
|
+
# Create the irbrc for the currently selected ruby installation.
|
702
705
|
if [[ -d "$rvm_ruby_home" ]] && [[ ! -s "$rvm_ruby_irbrc" ]] ; then
|
703
|
-
|
704
|
-
|
705
|
-
require "irb/completion" rescue nil
|
706
|
-
|
707
|
-
require "irb/ext/save-history"
|
708
|
-
IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.irb-history"
|
709
|
-
|
710
|
-
@prompt = {
|
711
|
-
:PROMPT_I => "${rvm_ruby_package_name} > ", # default prompt
|
712
|
-
:PROMPT_S => "${rvm_ruby_package_name}%l> ", # known continuation
|
713
|
-
:PROMPT_C => "${rvm_ruby_package_name} > ",
|
714
|
-
:PROMPT_N => "${rvm_ruby_package_name} ?> ", # unknown continuation
|
715
|
-
:RETURN => " => %s \n",
|
716
|
-
:AUTO_INDENT => true
|
717
|
-
}
|
718
|
-
IRB.conf[:PROMPT][:RVM] = @prompt
|
719
|
-
IRB.conf[:PROMPT_MODE] = :RVM
|
720
|
-
|
721
|
-
load '$HOME/.irbrc' if File.exists?('$HOME/.irbrc') rescue nil
|
722
|
-
|
723
|
-
Config
|
724
|
-
)
|
725
|
-
touch $rvm_ruby_irbrc
|
726
|
-
echo -e "\n$rvm_ruby_irbrc_file" > $rvm_ruby_home/.irbrc
|
727
|
-
unset rvm_ruby_irbrc_file
|
706
|
+
cp $rvm_path/scripts/irbrc $rvm_ruby_irbrc
|
728
707
|
fi
|
729
708
|
}
|
730
709
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rvm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.66
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Wayne E. Seguin
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-10-
|
12
|
+
date: 2009-10-29 00:00:00 -04:00
|
13
13
|
default_executable: rvm-install
|
14
14
|
dependencies: []
|
15
15
|
|
@@ -39,6 +39,8 @@ files:
|
|
39
39
|
- scripts/gems
|
40
40
|
- scripts/gemsync
|
41
41
|
- scripts/install
|
42
|
+
- scripts/irbrc
|
43
|
+
- scripts/irbrc.rb
|
42
44
|
- scripts/ruby-installer
|
43
45
|
- scripts/rvm
|
44
46
|
- scripts/rvm-install
|