initial commit

This commit is contained in:
2023-07-01 07:23:51 +01:00
commit 984322d789
29 changed files with 1772 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv --version
echo.
echo Displays the version number of this rbenv release, including the
echo current revision from git, if available.
echo.
echo The format of the git revision is:
echo ^<version^>-^<num_commits^>-^<git_sha^>
echo where `num_commits` is the number of commits since `version` was
echo tagged.
echo.
EXIT /B
)
echo rbenv 0.0.5-06

View File

@@ -0,0 +1,13 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv commands
echo.
echo List all available rbenv commands
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

View File

@@ -0,0 +1,49 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv duplicate ^<available_envirment^> ^<new_enviroment^>
echo.
echo Duplicate your enviroment.
echo.
echo ex.^) rbenv duplicate 2.3.0 myapp_env
echo.
echo To use when you want to create a sandbox and
echo the environment when building application-specific environment.
EXIT /B
)
set src=%~1
set dst=%~2
set src=%src:\=_%
set dst=%dst:\=_%
IF NOT EXIST %~dp0..\versions\%src%\ (
echo %src% is not exist
goto illegal
)
IF EXIST %~dp0..\versions\%dst%\ (
echo %dst% is already exist
goto illegal
)
IF "%dst%" == "" (
echo new_enviroment "%dst%" is illegal env name
goto illegal
)
IF "%src%" == "" (
echo available_envirment "%src%" is illegal env name
goto illegal
)
IF "%src%" == "." (
echo available_envirment "%src%" is illegal env name
goto illegal
)
IF "%src%" == ".." (
echo available_envirment "%src%" is illegal env name
goto illegal
)
xcopy "%~dp0..\versions\%src%" "%~dp0..\versions\%dst%\" /E /H /R /K /Y /I /F
:illegal
set src=
set dst=

19
libexec/rbenv-exec.bat Normal file
View File

@@ -0,0 +1,19 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv exec ^<command^> [arg1 arg2...]
echo.
echo Runs an executable by first preparing PATH so that the selected Ruby
echo version's `bin' directory is at the front.
echo.
echo For example, if the currently selected Ruby version is 1.9.3-p327:
echo rbenv exec bundle install
echo.
echo is equivalent to:
echo PATH="$RBENV_ROOT/versions/1.9.3-p327/bin:$PATH" bundle install
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

37
libexec/rbenv-export.bat Normal file
View File

@@ -0,0 +1,37 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv duplicate ^<available_envirment^> ^<new_enviroment^>
echo.
echo Export your enviroment.
echo.
echo ex.^) rbenv duplicate 2.3.0 ./vendor/ruby
echo.
echo To use when you want to build application-specific environment.
EXIT /B
)
set src=%~1
set src=%src:\=_%
IF NOT EXIST %~dp0..\versions\%src%\ (
echo %src% is not exist
goto illegal
)
IF "%src%" == "" (
echo available_envirment "%src%" is illegal env name
goto illegal
)
IF "%src%" == "." (
echo available_envirment "%src%" is illegal env name
goto illegal
)
IF "%src%" == ".." (
echo available_envirment "%src%" is illegal env name
goto illegal
)
xcopy "%~dp0..\versions\%src%" %2 /E /H /R /K /Y /I /F
:illegal
set src=

15
libexec/rbenv-global.bat Normal file
View File

@@ -0,0 +1,15 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv global ^<version^>
echo.
echo Sets the global Ruby version. You can override the global version at
echo any time by setting a directory-specific version with `rbenv local'
echo or by setting the `RBENV_VERSION' environment variable.
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

30
libexec/rbenv-help.bat Normal file
View File

@@ -0,0 +1,30 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv ^<command^> [^<args^>]
echo.
echo Some useful rbenv commands are:
echo commands List all available rbenv commands
echo local Set or show the local application-specific Ruby version
echo global Set or show the global Ruby version
echo shell Set or show the shell-specific Ruby version
echo install Install a Ruby version using ruby-build
echo uninstall Uninstall a specific Ruby version
echo rehash Rehash rbenv shims (run this after installing executables)
echo version Show the current Ruby version and its origin
echo versions List all Ruby versions available to rbenv
echo which Display the full path to an executable
echo whence List all Ruby versions that contain the given executable
echo.
echo See `rbenv help ^<command^>' for information on a specific command.
echo For full documentation, see: https://github.com/rbenv/rbenv#readme
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

520
libexec/rbenv-install.vbs Normal file
View File

@@ -0,0 +1,520 @@
Option Explicit
Dim objws
Dim objfs
Set objws = WScript.CreateObject("WScript.Shell")
Set objfs = CreateObject("Scripting.FileSystemObject")
Dim strCurrent
Dim strRbenvHome
Dim strDirCache
Dim strDirVers
Dim strDirLibs
Dim strVerFile
strCurrent = objfs.GetAbsolutePathName(".")
strRbenvHome = objfs.getParentFolderName(objfs.getParentFolderName(WScript.ScriptFullName))
strDirCache = strRbenvHome & "\install_cache"
strDirVers = strRbenvHome & "\versions"
strDirLibs = strRbenvHome & "\libexec"
strVerFile = "\.ruby_version"
Dim tool7z
Dim strDirDevKit
tool7z = """" & strRbenvHome & "\tools\7z\7zdec.exe"" x "
strDirDevKit = strRbenvHome & "\tools\DevKit"
Sub ShowHelp()
Wscript.echo "Usage: rbenv install [-f|-s] <version>"
Wscript.echo " rbenv install [-f|-s] <definition-file>"
Wscript.echo " rbenv install -l|--list"
Wscript.echo ""
Wscript.echo " -l/--list List all available versions"
Wscript.echo " -f/--force Install even if the version appears to be installed already"
Wscript.echo " -s/--skip-existing Skip if the version appears to be installed already"
Wscript.echo ""
Wscript.Quit
End Sub
Dim listDevKit
listDevKit = Array( _
Array("i386","http://dl.bintray.com/oneclick/rubyinstaller/","DevKit-mingw64-32-4.7.2-20130224-1151-sfx.exe" ),_
Array("x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","DevKit-mingw64-64-4.7.2-20130224-1432-sfx.exe" ),_
Array("tdm" ,"http://dl.bintray.com/oneclick/rubyinstaller/","DevKit-tdm-32-4.5.2-20111229-1559-sfx.exe" ) _
)
Dim listEnv
Dim listEnv_i386
listEnv = Array(_
Array("2.7.1-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.1-1/","rubyinstaller-2.7.1-1-x86.7z" ,"bundled"),_
Array("2.7.1-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.1-1/","rubyinstaller-2.7.1-1-x86.7z" ,"bundled"),_
Array("2.7.0-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.0-1/","rubyinstaller-2.7.0-1-x86.7z" ,"bundled"),_
Array("2.7.0-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.0-1/","rubyinstaller-2.7.0-1-x86.7z" ,"bundled"),_
Array("2.6.6-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.6-1/","rubyinstaller-2.6.6-1-x86.7z" ,"bundled"),_
Array("2.6.6-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.6-1/","rubyinstaller-2.6.6-1-x64.7z" ,"bundled"),_
Array("2.6.4-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.4-1/","rubyinstaller-2.6.4-1-x86.7z" ,"bundled"),_
Array("2.6.4-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.4-1/","rubyinstaller-2.6.4-1-x64.7z" ,"bundled"),_
Array("2.6.0-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.0-1/","rubyinstaller-devkit-2.6.0-1-x86.7z" ,"bundled"),_
Array("2.6.0-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.0-1/","rubyinstaller-devkit-2.6.0-1-x64.7z" ,"bundled"),_
Array("2.5.3-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.5.3-1/","rubyinstaller-devkit-2.5.3-1-x86.7z" ,"bundled"),_
Array("2.5.3-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.5.3-1/","rubyinstaller-devkit-2.5.3-1-x64.7z" ,"bundled"),_
Array("2.4.5-i386" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.4.5-1/","rubyinstaller-devkit-2.4.5-1-x86.7z" ,"bundled"),_
Array("2.4.5-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.4.5-1/","rubyinstaller-devkit-2.4.5-1-x64.7z" ,"bundled"),_
Array("2.3.3-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.3-i386-mingw32.7z" ,"i386"),_
Array("2.3.3-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.3-x64-mingw32.7z" ,"x64" ),_
Array("2.3.1-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.1-i386-mingw32.7z" ,"i386"),_
Array("2.3.1-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.1-x64-mingw32.7z" ,"x64" ),_
Array("2.3.0-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.0-i386-mingw32.7z" ,"i386"),_
Array("2.3.0-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.0-x64-mingw32.7z" ,"x64" ),_
Array("2.2.6-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.6-i386-mingw32.7z" ,"i386"),_
Array("2.2.6-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.6-x64-mingw32.7z" ,"x64" ),_
Array("2.2.5-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.5-i386-mingw32.7z" ,"i386"),_
Array("2.2.5-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.5-x64-mingw32.7z" ,"x64" ),_
Array("2.2.4-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.4-i386-mingw32.7z" ,"i386"),_
Array("2.2.4-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.4-x64-mingw32.7z" ,"x64" ),_
Array("2.2.3-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.3-i386-mingw32.7z" ,"i386"),_
Array("2.2.3-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.3-x64-mingw32.7z" ,"x64" ),_
Array("2.2.2-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.2-i386-mingw32.7z" ,"i386"),_
Array("2.2.2-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.2-x64-mingw32.7z" ,"x64" ),_
Array("2.2.1-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.1-i386-mingw32.7z" ,"i386"),_
Array("2.2.1-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.1-x64-mingw32.7z" ,"x64" ),_
Array("2.1.9-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.9-i386-mingw32.7z" ,"i386"),_
Array("2.1.9-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.9-x64-mingw32.7z" ,"x64" ),_
Array("2.1.8-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.8-i386-mingw32.7z" ,"i386"),_
Array("2.1.8-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.8-x64-mingw32.7z" ,"x64" ),_
Array("2.1.7-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.7-i386-mingw32.7z" ,"i386"),_
Array("2.1.7-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.7-x64-mingw32.7z" ,"x64" ),_
Array("2.1.6-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.6-i386-mingw32.7z" ,"i386"),_
Array("2.1.6-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.6-x64-mingw32.7z" ,"x64" ),_
Array("2.1.5-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.5-i386-mingw32.7z" ,"i386"),_
Array("2.1.5-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.5-x64-mingw32.7z" ,"x64" ),_
Array("2.1.4-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.4-i386-mingw32.7z" ,"i386"),_
Array("2.1.4-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.4-x64-mingw32.7z" ,"x64" ),_
Array("2.1.3-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.3-i386-mingw32.7z" ,"i386"),_
Array("2.1.3-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.3-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p648-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p648-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p648-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p648-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p647-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p647-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p647-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p647-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p645-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p645-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p645-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p645-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p643-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p643-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p643-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p643-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p598-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p598-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p598-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p598-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p594-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p594-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p594-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p594-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p576-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p576-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p576-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p576-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p481-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p481-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p481-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p481-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p451-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p451-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p451-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p451-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p353-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p353-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p353-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p353-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p247-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p247-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p247-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p247-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p195-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p195-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p195-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p195-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p0-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p0-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p0-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p0-x64-mingw32.7z" ,"x64" ),_
Array("1.9.3-p551-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p551-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p550-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p550-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p545-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p545-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p484-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p484-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p448-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p448-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p429-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p429-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p392-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p392-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p385-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p385-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p374-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p374-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p362-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p362-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p327-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p327-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p286-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p286-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p194-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p194-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p125-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p125-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p0-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p0-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p290-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p290-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p180-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p180-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p136-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p136-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p0-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p0-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p374-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p374-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p371-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p371-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p370-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p370-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p358-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p358-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p357-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p357-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p352-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p352-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p334-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p334-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p330-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p330-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p302-i386" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p302-i386-mingw32.7z" ,"tdm" ) _
)
listEnv_i386 = Array( _
Array("3.1.2" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.1.2-1/","rubyinstaller-3.1.2-1-x86.7z" ,"bundled"),_
Array("3.1.2-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.1.2-1/","rubyinstaller-3.1.2-1-x64.7z" ,"bundled"),_
Array("3.1.1" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.1.1-1/","rubyinstaller-3.1.1-1-x86.7z" ,"bundled"),_
Array("3.1.1-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.1.1-1/","rubyinstaller-3.1.1-1-x64.7z" ,"bundled"),_
Array("3.1.0" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.1.0-1/","rubyinstaller-3.1.0-1-x86.7z" ,"bundled"),_
Array("3.1.0-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.1.0-1/","rubyinstaller-3.1.0-1-x64.7z" ,"bundled"),_
Array("3.0.4" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.4-1/","rubyinstaller-3.0.4-1-x86.7z" ,"bundled"),_
Array("3.0.4-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.4-1/","rubyinstaller-3.0.4-1-x64.7z" ,"bundled"),_
Array("3.0.3" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.3-1/","rubyinstaller-3.0.3-1-x86.7z" ,"bundled"),_
Array("3.0.3-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.3-1/","rubyinstaller-3.0.3-1-x64.7z" ,"bundled"),_
Array("3.0.2" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.2-1/","rubyinstaller-3.0.2-1-x86.7z" ,"bundled"),_
Array("3.0.2-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.2-1/","rubyinstaller-3.0.2-1-x64.7z" ,"bundled"),_
Array("3.0.1" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.1-1/","rubyinstaller-3.0.1-1-x86.7z" ,"bundled"),_
Array("3.0.1-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.1-1/","rubyinstaller-3.0.1-1-x64.7z" ,"bundled"),_
Array("3.0.0" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.0-1/","rubyinstaller-3.0.0-1-x86.7z" ,"bundled"),_
Array("3.0.0-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-3.0.0-1/","rubyinstaller-3.0.0-1-x64.7z" ,"bundled"),_
Array("2.7.6" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.6-1/","rubyinstaller-2.7.6-1-x86.7z" ,"bundled"),_
Array("2.7.6-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.6-1/","rubyinstaller-2.7.6-1-x64.7z" ,"bundled"),_
Array("2.7.5" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.5-1/","rubyinstaller-2.7.5-1-x86.7z" ,"bundled"),_
Array("2.7.5-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.5-1/","rubyinstaller-2.7.5-1-x64.7z" ,"bundled"),_
Array("2.7.4" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.4-1/","rubyinstaller-2.7.4-1-x86.7z" ,"bundled"),_
Array("2.7.4-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.4-1/","rubyinstaller-2.7.4-1-x64.7z" ,"bundled"),_
Array("2.7.3" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.3-1/","rubyinstaller-2.7.3-1-x86.7z" ,"bundled"),_
Array("2.7.3-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.3-1/","rubyinstaller-2.7.3-1-x64.7z" ,"bundled"),_
Array("2.7.2" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.2-1/","rubyinstaller-2.7.2-1-x86.7z" ,"bundled"),_
Array("2.7.2-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.2-1/","rubyinstaller-2.7.2-1-x64.7z" ,"bundled"),_
Array("2.7.1" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.1-1/","rubyinstaller-2.7.1-1-x86.7z" ,"bundled"),_
Array("2.7.1-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.1-1/","rubyinstaller-2.7.1-1-x64.7z" ,"bundled"),_
Array("2.7.0" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.0-1/","rubyinstaller-2.7.0-1-x86.7z" ,"bundled"),_
Array("2.7.0-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.7.0-1/","rubyinstaller-2.7.0-1-x64.7z" ,"bundled"),_
Array("2.6.10" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.10-1/","rubyinstaller-2.6.10-1-x86.7z" ,"bundled"),_
Array("2.6.10-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.10-1/","rubyinstaller-2.6.10-1-x64.7z" ,"bundled"),_
Array("2.6.9" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.9-1/","rubyinstaller-2.6.9-1-x86.7z" ,"bundled"),_
Array("2.6.9-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.9-1/","rubyinstaller-2.6.9-1-x64.7z" ,"bundled"),_
Array("2.6.8" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.8-1/","rubyinstaller-2.6.8-1-x86.7z" ,"bundled"),_
Array("2.6.8-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.8-1/","rubyinstaller-2.6.8-1-x64.7z" ,"bundled"),_
Array("2.6.7" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.7-1/","rubyinstaller-2.6.7-1-x86.7z" ,"bundled"),_
Array("2.6.7-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.7-1/","rubyinstaller-2.6.7-1-x64.7z" ,"bundled"),_
Array("2.6.6" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.6-1/","rubyinstaller-2.6.6-1-x86.7z" ,"bundled"),_
Array("2.6.6-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.6-1/","rubyinstaller-2.6.6-1-x64.7z" ,"bundled"),_
Array("2.6.4" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.4-1/","rubyinstaller-2.6.4-1-x86.7z" ,"bundled"),_
Array("2.6.4-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.4-1/","rubyinstaller-2.6.4-1-x64.7z" ,"bundled"),_
Array("2.6.0" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.0-1/","rubyinstaller-2.6.0-1-x86.7z" ,"bundled"),_
Array("2.6.0-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/RubyInstaller-2.6.0-1/","rubyinstaller-2.6.0-1-x64.7z" ,"bundled"),_
Array("2.5.9" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.5.9-1/","rubyinstaller-2.5.9-1-x86.7z" ,"bundled"),_
Array("2.5.9-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.5.9-1/","rubyinstaller-2.5.9-1-x64.7z" ,"bundled"),_
Array("2.5.3" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.5.3-1/","rubyinstaller-2.5.3-1-x86.7z" ,"bundled"),_
Array("2.5.3-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.5.3-1/","rubyinstaller-2.5.3-1-x64.7z" ,"bundled"),_
Array("2.4.5" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.4.5-1/","rubyinstaller-2.4.5-1-x86.7z" ,"bundled"),_
Array("2.4.5-x64" ,"https://github.com/oneclick/rubyinstaller2/releases/download/rubyinstaller-2.4.5-1/","rubyinstaller-2.4.5-1-x64.7z" ,"bundled"),_
Array("2.3.3" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.3-i386-mingw32.7z" ,"i386"),_
Array("2.3.3-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.3-x64-mingw32.7z" ,"x64" ),_
Array("2.3.1" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.1-i386-mingw32.7z" ,"i386"),_
Array("2.3.1-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.1-x64-mingw32.7z" ,"x64" ),_
Array("2.3.0" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.0-i386-mingw32.7z" ,"i386"),_
Array("2.3.0-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.3.0-x64-mingw32.7z" ,"x64" ),_
Array("2.2.6" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.6-i386-mingw32.7z" ,"i386"),_
Array("2.2.6-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.6-x64-mingw32.7z" ,"x64" ),_
Array("2.2.5" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.5-i386-mingw32.7z" ,"i386"),_
Array("2.2.5-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.5-x64-mingw32.7z" ,"x64" ),_
Array("2.2.4" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.4-i386-mingw32.7z" ,"i386"),_
Array("2.2.4-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.4-x64-mingw32.7z" ,"x64" ),_
Array("2.2.3" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.3-i386-mingw32.7z" ,"i386"),_
Array("2.2.3-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.3-x64-mingw32.7z" ,"x64" ),_
Array("2.2.2" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.2-i386-mingw32.7z" ,"i386"),_
Array("2.2.2-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.2-x64-mingw32.7z" ,"x64" ),_
Array("2.2.1" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.1-i386-mingw32.7z" ,"i386"),_
Array("2.2.1-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.2.1-x64-mingw32.7z" ,"x64" ),_
Array("2.1.9" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.9-i386-mingw32.7z" ,"i386"),_
Array("2.1.9-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.9-x64-mingw32.7z" ,"x64" ),_
Array("2.1.8" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.8-i386-mingw32.7z" ,"i386"),_
Array("2.1.8-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.8-x64-mingw32.7z" ,"x64" ),_
Array("2.1.7" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.7-i386-mingw32.7z" ,"i386"),_
Array("2.1.7-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.7-x64-mingw32.7z" ,"x64" ),_
Array("2.1.6" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.6-i386-mingw32.7z" ,"i386"),_
Array("2.1.6-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.6-x64-mingw32.7z" ,"x64" ),_
Array("2.1.5" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.5-i386-mingw32.7z" ,"i386"),_
Array("2.1.5-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.5-x64-mingw32.7z" ,"x64" ),_
Array("2.1.4" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.4-i386-mingw32.7z" ,"i386"),_
Array("2.1.4-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.4-x64-mingw32.7z" ,"x64" ),_
Array("2.1.3" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.3-i386-mingw32.7z" ,"i386"),_
Array("2.1.3-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.1.3-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p648" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p648-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p648-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p648-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p647" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p647-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p647-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p647-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p645" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p645-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p645-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p645-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p643" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p643-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p643-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p643-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p598" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p598-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p598-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p598-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p594" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p594-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p594-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p594-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p576" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p576-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p576-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p576-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p481" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p481-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p481-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p481-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p451" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p451-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p451-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p451-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p353" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p353-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p353-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p353-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p247" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p247-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p247-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p247-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p195" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p195-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p195-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p195-x64-mingw32.7z" ,"x64" ),_
Array("2.0.0-p0" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p0-i386-mingw32.7z" ,"i386"),_
Array("2.0.0-p0-x64" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-2.0.0-p0-x64-mingw32.7z" ,"x64" ),_
Array("1.9.3-p551" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p551-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p550" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p550-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p545" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p545-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p484" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p484-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p448" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p448-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p429" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p429-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p392" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p392-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p385" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p385-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p374" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p374-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p362" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p362-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p327" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p327-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p286" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p286-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p194" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p194-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p125" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p125-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.3-p0" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.3-p0-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p290" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p290-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p180" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p180-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p136" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p136-i386-mingw32.7z" ,"tdm" ),_
Array("1.9.2-p0" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.9.2-p0-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p374" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p374-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p371" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p371-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p370" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p370-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p358" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p358-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p357" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p357-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p352" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p352-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p334" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p334-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p330" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p330-i386-mingw32.7z" ,"tdm" ),_
Array("1.8.7-p302" ,"http://dl.bintray.com/oneclick/rubyinstaller/","ruby-1.8.7-p302-i386-mingw32.7z" ,"tdm" ) _
)
Function DownloadFile(strUrl,strFile)
Dim objHttp
Dim httpProxy
Set objHttp = Wscript.CreateObject("Msxml2.ServerXMLHTTP")
on error resume next
Call objHttp.Open("GET", strUrl, False )
if Err.Number <> 0 then
Wscript.Echo Err.Description
Wscript.Quit
end if
httpProxy = objws.ExpandEnvironmentStrings("%http_proxy%")
if httpProxy <> "" AND httpProxy <> "%http_proxy%" Then
objHttp.setProxy 2, httpProxy
end if
objHttp.Send
if Err.Number <> 0 then
Wscript.Echo Err.Description
Wscript.Quit
end if
on error goto 0
if objHttp.status = 404 then
Wscript.Echo "404:file not found"
Wscript.Quit
end if
Dim Stream
Set Stream = Wscript.CreateObject("ADODB.Stream")
Stream.Open
Stream.Type = 1
Stream.Write objHttp.responseBody
Stream.SaveToFile strFile, 2
Stream.Close
End Function
Sub extractDevKit(cur)
If Not objfs.FolderExists( strDirDevKit ) Then objfs.CreateFolder(strDirDevKit)
If Not objfs.FolderExists( cur(1) ) Then objfs.CreateFolder(cur(1))
If Not objfs.FileExists(cur(2)) Then
objws.Run "%comspec% /c rmdir /s /q " & cur(1), 0 , true
objfs.CreateFolder(cur(1))
If objfs.FileExists(cur(4)) Then
objfs.CopyFile cur(4), cur(1)&"\", True
Else
download(cur)
End If
End If
If Not objfs.FileExists(cur(1) & "\dk.rb") Then
Wscript.echo "extract" & cur(0) & " ..."
objws.Run """" & cur(2) & """", 1 , true
End If
End Sub
Sub writeConfigYML(dev,cur)
Dim ofile
Set ofile = objfs.CreateTextFile(dev(1) & "\config.yml" , True )
ofile.WriteLine("- " & cur(1))
ofile.Close()
End Sub
Sub patchDevKit(dev,cur)
Wscript.echo "patch " & dev(0) & " to " & cur(0)
writeConfigYML dev,cur
objws.CurrentDirectory = dev(1)
objws.Run """" & cur(1) & "\bin\ruby.exe"" dk.rb install", 1 , true
objws.CurrentDirectory =strCurrent
End Sub
Sub installDevKit(cur)
Dim list
Dim dev
Dim idx
If cur(4) = "bundled" Then
objws.Run """" & cur(1) & "\bin\ridk.cmd"" install", 1 , true
Else
For Each list In listDevKit
If list(0) = cur(4) Then
dev=Array("DevKit_" & list(0), strDirDevKit&"\"&list(0), strDirDevKit&"\"&list(0)&"\"&list(2), list(1)&list(2), strDirCache&"\"&list(2))
extractDevKit dev
patchDevKit dev,cur
Exit Sub
End If
Next
End If
End Sub
Sub clear(cur)
If objfs.FolderExists(cur(1)) Then objfs.DeleteFolder cur(1),True
If objfs.FileExists( cur(2)) Then objfs.DeleteFile cur(2),True
End Sub
Sub download(cur)
Wscript.echo "download " & cur(0) & " ..."
DownloadFile cur(3) , cur(2)
End Sub
Sub extract(cur)
If Not objfs.FolderExists( strDirCache ) Then objfs.CreateFolder(strDirCache)
If Not objfs.FolderExists( strDirVers ) Then objfs.CreateFolder(strDirVers )
If objfs.FolderExists(cur(1)) Then Exit Sub
If Not objfs.FileExists(cur(2)) Then download(cur)
Wscript.echo "install " & cur(0) & " ..."
objws.CurrentDirectory = strDirCache
objws.Run tool7z & " """ & cur(2) & """" , 0 , true
objfs.MoveFolder strDirCache&"\"&objfs.GetBaseName(cur(2)) , cur(1)
installDevKit(cur)
objws.Run "rbenv rehash " & cur(0), 0, true
Wscript.echo "comlete! " & cur(0)
End Sub
Function GetCurrentVersionGlobal()
GetCurrentVersionGlobal = Null
Dim fname
Dim objFile
fname = strRbenvHome & "\version"
If objfs.FileExists( fname ) Then
Set objFile = objfs.OpenTextFile(fname)
If objFile.AtEndOfStream <> True Then
GetCurrentVersionGlobal = Array(objFile.ReadLine,fname)
End If
objFile.Close
End If
End Function
Function GetCurrentVersionLocal(path)
GetCurrentVersionLocal = Null
Dim fname
Dim objFile
Do While path <> ""
fname = path & strVerFile
If objfs.FileExists( fname ) Then
Set objFile = objfs.OpenTextFile(fname)
If objFile.AtEndOfStream <> True Then
GetCurrentVersionLocal = Array(objFile.ReadLine,fname)
End If
objFile.Close
Exit Function
End If
path = objfs.getParentFolderName(path)
Loop
End Function
Function GetCurrentVersionShell()
GetCurrentVersionShell = Null
Dim str
str=objws.ExpandEnvironmentStrings("%RBENV_VERSION%")
If str <> "%RBENV_VERSION%" Then
GetCurrentVersionShell = Array(str,"%RBENV_VERSION%")
End If
End Function
Function GetCurrentVersionNoError()
Dim str
str=GetCurrentVersionShell
If IsNull(str) Then str = GetCurrentVersionLocal(strCurrent)
If IsNull(str) Then str = GetCurrentVersionGlobal
GetCurrentVersionNoError = str
End Function
Sub main(arg)
If arg.Count = 0 Then ShowHelp
Dim idx
Dim optForce
Dim optSkip
Dim optList
Dim version
optForce=False
optSkip=False
optList=False
version=""
For idx = 0 To arg.Count - 1
Select Case arg(idx)
Case "--help" ShowHelp
Case "-l" optList=True
Case "--list" optList=True
Case "-f" optForce=True
Case "--force" optForce=True
Case "-s" optSkip=True
Case "--skip-existing" optSkip=True
Case Else
version = arg(idx)
Exit For
End Select
Next
If version = "" Then
Dim ary
ary=GetCurrentVersionNoError()
If Not IsNull(ary) Then version=ary(0)
End If
Dim list
Dim cur
If optList Then
For Each list In listEnv_i386
Wscript.echo list(0)
Next
Exit Sub
ElseIf version <> "" Then
For Each list In listEnv_i386
If list(0) = version Then
cur=Array(list(0),strDirVers&"\"&list(0),strDirCache&"\"&list(2),list(1)&list(2),list(3))
If optForce Then clear(cur)
extract(cur)
Exit Sub
End If
Next
Wscript.echo "rbenv-install: definition not found: " & version
Wscript.echo ""
Wscript.echo "See all available versions with `rbenv install --list'."
Else
ShowHelp
End If
End Sub
main(WScript.Arguments)

23
libexec/rbenv-local.bat Normal file
View File

@@ -0,0 +1,23 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv local ^<version^>
echo rbenv local --unset
echo.
echo Sets the local application-specific Ruby version by writing the
echo version name to a file named `.ruby-version'.
echo.
echo When you run a Ruby command, rbenv will look for a `.ruby-version'
echo file in the current directory and each parent directory. If no such
echo file is found in the tree, rbenv will use the global Ruby version
echo specified with `rbenv global'. A version specified with the
echo `RBENV_VERSION' environment variable takes precedence over local
echo and global versions.
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

13
libexec/rbenv-rehash.bat Normal file
View File

@@ -0,0 +1,13 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv rehash
echo.
echo Rehash rbenv shims ^(run this after installing executables^)
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

15
libexec/rbenv-shell.bat Normal file
View File

@@ -0,0 +1,15 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv shell ^<version^>
echo rbenv shell --unset
echo.
echo Sets a shell-specific Ruby version by setting the `RBENV_VERSION'
echo environment variable in your shell. This version overrides local
echo application-specific versions and the global version.
echo.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

View File

@@ -0,0 +1,77 @@
Option Explicit
Dim objws
Dim objfs
Set objws = WScript.CreateObject("WScript.Shell")
Set objfs = CreateObject("Scripting.FileSystemObject")
Dim strCurrent
Dim strRbenvHome
Dim strDirCache
Dim strDirVers
Dim strDirLibs
strCurrent = objfs.GetAbsolutePathName(".")
strRbenvHome = objfs.getParentFolderName(objfs.getParentFolderName(WScript.ScriptFullName))
strDirCache = strRbenvHome & "\install_cache"
strDirVers = strRbenvHome & "\versions"
strDirLibs = strRbenvHome & "\libexec"
Sub ShowHelp()
Wscript.echo "Usage: rbenv uninstall [-f|--force] <version>"
Wscript.echo ""
Wscript.echo " -f Attempt to remove the specified version without prompting"
Wscript.echo " for confirmation. If the version does not exist, do not"
Wscript.echo " display an error message."
Wscript.echo ""
Wscript.echo "See `rbenv versions` for a complete list of installed versions."
Wscript.echo ""
Wscript.Quit
End Sub
Function IsVersion(version)
Dim re
Set re = new regexp
re.Pattern = "^[a-zA-Z_0-9-.]+$"
IsVersion = re.Test(version)
End Function
Sub main(arg)
If arg.Count = 0 Then ShowHelp
Dim idx
Dim optForce
Dim version
optForce=False
version=""
For idx = 0 To arg.Count - 1
Select Case arg(idx)
Case "--help" ShowHelp
Case "-f" optForce=True
Case "--force" optForce=True
Case Else
version = arg(idx)
Exit For
End Select
Next
Dim str,ans
ans=""
str=strDirVers&"\"&version
If IsVersion(version) And objfs.FolderExists(str) Then
ans="y"
If Not optForce Then
Wscript.StdOut.Write "rbenv: remove "&str&"? "
ans=WScript.StdIn.ReadLine
End If
Else
If Not optForce Then Wscript.echo "rbenv: version `"&version&"' not installed"
Wscript.Quit
End If
If ans="y" Or ans="Y" Then objfs.DeleteFolder str , True
End Sub
main(WScript.Arguments)

13
libexec/rbenv-version.bat Normal file
View File

@@ -0,0 +1,13 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv version
echo.
echo Shows the currently selected Ruby version and how it was
echo selected. To obtain only the version string, use `rbenv
echo version-name'.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

View File

@@ -0,0 +1,11 @@
@echo off
setlocal
if "%1" == "--help" (
echo Usage: rbenv versions [--bare] [--skip-aliases]
echo.
echo Lists all Ruby versions found in `$RBENV_ROOT/versions/*'.
EXIT /B
)
rem Implementation of this command is in the rbenv.vbs file .

408
libexec/rbenv.vbs Normal file
View File

@@ -0,0 +1,408 @@
Option Explicit
Dim objws
Dim objfs
Set objws = WScript.CreateObject("WScript.Shell")
Set objfs = CreateObject("Scripting.FileSystemObject")
Dim strCurrent
Dim strRbenvHome
Dim strDirCache
Dim strDirVers
Dim strDirLibs
Dim strVerFile
strCurrent = objfs.GetAbsolutePathName(".")
strRbenvHome = objfs.getParentFolderName(objfs.getParentFolderName(WScript.ScriptFullName))
strDirCache = strRbenvHome & "\install_cache"
strDirVers = strRbenvHome & "\versions"
strDirLibs = strRbenvHome & "\libexec"
strVerFile = "\.ruby_version"
Function IsVersion(version)
Dim re
Set re = new regexp
re.Pattern = "^[a-zA-Z_0-9-.]+$"
IsVersion = re.Test(version)
End Function
Function GetCurrentVersionGlobal()
GetCurrentVersionGlobal = Null
Dim fname
Dim objFile
fname = strRbenvHome & "\version"
If objfs.FileExists( fname ) Then
Set objFile = objfs.OpenTextFile(fname)
If objFile.AtEndOfStream <> True Then
GetCurrentVersionGlobal = Array(objFile.ReadLine,fname)
End If
objFile.Close
End If
End Function
Function GetCurrentVersionLocal(path)
GetCurrentVersionLocal = Null
Dim fname
Dim objFile
Do While path <> ""
fname = path & strVerFile
If objfs.FileExists( fname ) Then
Set objFile = objfs.OpenTextFile(fname)
If objFile.AtEndOfStream <> True Then
GetCurrentVersionLocal = Array(objFile.ReadLine,fname)
End If
objFile.Close
Exit Function
End If
path = objfs.getParentFolderName(path)
Loop
End Function
Function GetCurrentVersionShell()
GetCurrentVersionShell = Null
Dim str
str=objws.ExpandEnvironmentStrings("%RBENV_VERSION%")
If str <> "%RBENV_VERSION%" Then
GetCurrentVersionShell = Array(str,"%RBENV_VERSION%")
End If
End Function
Function GetCurrentVersion()
Dim str
str=GetCurrentVersionShell
If IsNull(str) Then str = GetCurrentVersionLocal(strCurrent)
If IsNull(str) Then str = GetCurrentVersionGlobal
If IsNull(str) Then Err.Raise vbError + 1, "version not found", "please set 'rbenv global <version>'"
GetCurrentVersion = str
End Function
Function GetCurrentVersionNoError()
Dim str
str=GetCurrentVersionShell
If IsNull(str) Then str = GetCurrentVersionLocal(strCurrent)
If IsNull(str) Then str = GetCurrentVersionGlobal
GetCurrentVersionNoError = str
End Function
Function GetBinDir(ver)
Dim str
str=strDirVers & "\" & ver & "\bin"
If Not(IsVersion(ver) And objfs.FolderExists(str)) Then Err.Raise vbError + 2, "rbenv", "version `"&ver&"' not installed"
GetBinDir = str
End Function
Function GetCommandList()
Dim cmdList
Set cmdList = CreateObject("Scripting.Dictionary")'"System.Collections.SortedList"
Dim re
Set re = new regexp
re.Pattern = "\\rbenv-([a-zA-Z_0-9-]+)\.(bat|vbs)$"
Dim file
Dim mts
For Each file In objfs.GetFolder(strDirLibs).Files
Set mts=re.Execute(file)
If mts.Count > 0 Then
cmdList.Add mts(0).submatches(0), file
End If
Next
Set GetCommandList = cmdList
End Function
Sub ExecCommand(str)
Dim ofile
Set ofile = objfs.CreateTextFile(strRbenvHome & "\exec.bat" , True )
ofile.WriteLine(str)
ofile.Close()
End Sub
Sub ShowHelp()
Wscript.echo "Usage: rbenv <command> [<args>]"
Wscript.echo ""
Wscript.echo "Some useful rbenv commands are:"
Wscript.echo " commands List all available rbenv commands"
Wscript.echo " local Set or show the local application-specific Ruby version"
Wscript.echo " global Set or show the global Ruby version"
Wscript.echo " shell Set or show the shell-specific Ruby version"
Wscript.echo " install Install a Ruby version using ruby-build"
Wscript.echo " uninstall Uninstall a specific Ruby version"
Wscript.echo " rehash Rehash rbenv shims (run this after installing executables)"
Wscript.echo " version Show the current Ruby version and its origin"
Wscript.echo " versions List all Ruby versions available to rbenv"
Wscript.echo " exec Runs an executable by first preparing PATH so that the selected Ruby"
Wscript.echo ""
Wscript.echo "See `rbenv help <command>' for information on a specific command."
Wscript.echo "For full documentation, see: https://github.com/rbenv/rbenv#readme"
Exit Sub
Wscript.echo " which Display the full path to an executable"
Wscript.echo " whence List all Ruby versions that contain the given executable"
End Sub
Sub CommandHelp(arg)
If arg.Count > 1 Then
Dim list
Set list=GetCommandList
If list.Exists(arg(1)) Then
ExecCommand(list(arg(1)) & " --help")
Else
Wscript.echo "unknown rbenv command '"&arg(1)&"'"
End If
Else
ShowHelp
End If
End Sub
Sub CommandRehash(arg)
Dim strDirShims
strDirShims= strRbenvHome & "\shims"
If Not objfs.FolderExists( strDirShims ) Then objfs.CreateFolder(strDirShims)
Dim ofile
Dim file
For Each file In objfs.GetFolder(strDirShims).Files
objfs.DeleteFile file, True
Next
For Each file In objfs.GetFolder(GetBinDir(GetCurrentVersion()(0))).Files
If objfs.GetExtensionName(file) = "exe" or objfs.GetExtensionName(file) = "bat" or objfs.GetExtensionName(file) = "cmd" Then
Set ofile = objfs.CreateTextFile(strDirShims & "\" & objfs.GetBaseName( file ) & ".bat" )
ofile.WriteLine("@echo off")
ofile.WriteLine("rbenv exec %~n0 %*")
ofile.Close()
Set ofile = objfs.CreateTextFile(strDirShims & "\" & objfs.GetBaseName( file ) )
ofile.WriteLine("#!/bin/sh")
ofile.WriteLine("rbenv exec $(basename ""$0"") $*")
ofile.Close()
End If
Next
If arg.Count < 2 Then
Exit Sub
End If
If arg(1) <> "bundle" Then
Exit Sub
End If
Dim oExec,str,re,mts
set oExec = objws.Exec("bundle.bat config")
Do While oExec.Status = 0
WScript.Sleep 100
Loop
str = oExec.StdOut.ReadAll
set re=new regexp
re.multiline=true
re.pattern="^path\r\n.*\((.+?)\)\: ""(.+?)"""
set mts=re.execute(str)
if mts.count > 0 then
str= mts(0).submatches(0) & "/../../" & mts(0).submatches(1)
set oExec = objws.Exec("where -R """ & Replace(str,"/","\") &""" *.bat")
Do While oExec.Status = 0
WScript.Sleep 100
Loop
Do While Not oExec.StdOut.AtEndOfStream
str = oExec.StdOut.ReadLine
Set ofile = objfs.CreateTextFile(strDirShims & "\" & objfs.GetBaseName( str ) & ".bat" )
ofile.WriteLine("@echo off")
ofile.WriteLine("call bundle show > NUL")
ofile.WriteLine("if ERRORLEVEL 1 (")
ofile.WriteLine("rbenv exec %~n0 %*")
ofile.WriteLine(") else (")
ofile.WriteLine("bundle exec %~n0 %*")
ofile.WriteLine(")")
ofile.Close()
Set ofile = objfs.CreateTextFile(strDirShims & "\" & objfs.GetBaseName( str ) )
ofile.WriteLine("#!/bin/sh")
ofile.WriteLine("if bundle show >/dev/null; then")
ofile.WriteLine("bundle exec $(basename ""$0"") $*")
ofile.WriteLine("else")
ofile.WriteLine("rbenv exec $(basename ""$0"") $*")
ofile.WriteLine("fi")
ofile.Close()
Loop
end if
End Sub
Sub CommandExecute(arg)
Dim str
Dim dstr
dstr=GetBinDir(GetCurrentVersion()(0))
str="set PATH=" & dstr & ";%PATH:&=^&%" & vbCrLf
If arg.Count > 1 Then
str=str & """" & dstr & "\" & arg(1) & """"
Dim idx
If arg.Count > 2 Then
For idx = 2 To arg.Count - 1
str=str & " """& arg(idx) &""""
Next
End If
End If
ExecCommand(str)
End Sub
Sub CommandGlobal(arg)
If arg.Count < 2 Then
Dim ver
ver=GetCurrentVersionGlobal()
If IsNull(ver) Then
Wscript.echo "no global version configured"
Else
Wscript.echo ver(0)
End If
Else
GetBinDir(arg(1))
Dim ofile
Set ofile = objfs.CreateTextFile( strRbenvHome & "\version" , True )
ofile.WriteLine(arg(1))
ofile.Close()
End If
End Sub
Sub CommandLocal(arg)
Dim ver
If arg.Count < 2 Then
ver=GetCurrentVersionLocal(strCurrent)
If IsNull(ver) Then
Wscript.echo "no local version configured for this directory"
Else
Wscript.echo ver(0)
End If
Else
ver=arg(1)
If ver = "--unset" Then
ver = ""
objfs.DeleteFile strCurrent & strVerFile, True
Exit Sub
Else
GetBinDir(ver)
End If
Dim ofile
Set ofile = objfs.CreateTextFile( strCurrent & strVerFile , True )
ofile.WriteLine(ver)
ofile.Close()
End If
End Sub
Sub CommandShell(arg)
Dim ver
If arg.Count < 2 Then
ver=GetCurrentVersionShell
If IsNull(ver) Then
Wscript.echo "no shell-specific version configured"
Else
Wscript.echo ver(0)
End If
Else
ver=arg(1)
If ver = "--unset" Then
ver = ""
Else
GetBinDir(ver)
End If
ExecCommand("endlocal"&vbCrLf&"set RBENV_VERSION=" & ver)
End If
End Sub
Sub CommandVersion(arg)
If Not objfs.FolderExists( strDirVers ) Then objfs.CreateFolder(strDirVers)
Dim curVer
curVer=GetCurrentVersion
Wscript.echo curVer(0) & " (set by " &curVer(1)&")"
End Sub
Sub CommandVersions(arg)
Dim isBare
isBare=False
If arg.Count > 2 Then
If arg(1) = "--bare" Then isBare=True
End If
If Not objfs.FolderExists( strDirVers ) Then objfs.CreateFolder(strDirVers)
Dim curVer
curVer=GetCurrentVersionNoError
If IsNull(curVer) Then
curVer=Array("","")
End If
Dim dir
Dim ver
For Each dir In objfs.GetFolder(strDirVers).subfolders
ver=objfs.GetFileName( dir )
If isBare Then
Wscript.echo ver
ElseIf ver = curVer(0) Then
Wscript.echo "* " & ver & " (set by " &curVer(1)&")"
Else
Wscript.echo " " & ver
End If
Next
End Sub
Sub PlugIn(arg)
Dim fname
Dim idx
Dim str
fname = strDirLibs & "\rbenv-" & arg(0)
If objfs.FileExists( fname & ".bat" ) Then
str="""" & fname & ".bat"""
ElseIf objfs.FileExists( fname & ".vbs" ) Then
str="cscript //nologo """ & fname & ".vbs"""
Else
Wscript.echo "rbenv: no such command `"&arg(0)&"'"
Wscript.Quit
End If
For idx = 1 To arg.Count - 1
str=str & " """& arg(idx) &""""
Next
ExecCommand(str)
End Sub
Sub CommandCommands(arg)
Dim cname
For Each cname In GetCommandList()
Wscript.echo cname
Next
End Sub
Sub Dummy()
Wscript.echo "command not implement"
End Sub
Sub main(arg)
If arg.Count = 0 Then
ShowHelp
Else
Select Case arg(0)
Case "exec" CommandExecute(arg)
Case "rehash" CommandRehash(arg)
Case "global" CommandGlobal(arg)
Case "local" CommandLocal(arg)
Case "shell" CommandShell(arg)
Case "version" CommandVersion(arg)
Case "versions" CommandVersions(arg)
Case "commands" CommandCommands(arg)
Case "help" CommandHelp(arg)
Case Else PlugIn(arg)
End Select
End If
End Sub
main(WScript.Arguments)