Rubinius is an implementation of the Ruby programming language, in Ruby!
Rubinius includes in it's core:
- A bytecode virtual machine
- A parser
- A bytecode compiler
- A garbage collector
- A JIT native machine code compiler
More importantly Rubinius is built in Ruby so it has the Ruby Core with standard libraries.
This allows your average Ruby developer to understand exactly what goes on inside as well as easier committing to the project.
Rubinius currently is compatible with Ruby 1.8.7
, MRI*.
* Support for Ruby 1.9.2
is coming soon.
Rubinius runs on Mac OS X and many Unix or Linux operating systems*.
If you have rvm
setup you should skip ahead.
For more information about building and running Rubinius, run rake docs
and go here.
* Support for Microsoft Windows is coming soon.
The requirements for installing Rubinius are a working installation of:
To install Rubinius from source use the following steps:
- In your Terminal type:
git clone git://github.com/evanphx/rubinius.git
- Then type:
cd rubinius
- And:
./configure --prefix=/install/dir
, where the path/install/dir
should be where you want it to be installed at. - Finally finish with:
rake install
Once this finishes follow the given directions to add the bin directory to your PATH.
Rubinius comes with Ruby Gems built-in, but installing a gem is not too different:
rbx gem install gem_name
You can access the built-in documentation by running rbx docs
.
The Ruby Version Manager provides a much easier rbx setup and installation process.
To learn more about rvm
simply visit the website.
In order to view the dependency list to preinstall for rbx type rvm notes
.
Assuming all Rubinius dependencies have been preinstalled on the system, you may now install Rubinius either latest or head as follows:
rvm install rbx # Installs latest release (defaulted to install head)
or
rvm install rbx-head # Installs Rubinius master branch from github
Once installed, type rvm use rbx
into the current shell session.
Making Rubinius the default in new shells is as easy as: rvm use rbx --default
.
Rubinius has been under development as a public open-source project since November 2006. Rubinius development is sponsored by Engine Yard, Inc. and assisted by the generous work of over 100 contributors.
At version 1.1 Rubinius is significantly feature-complete. You can expect to have your Ruby code will run correctly. Additionally, many MRI C extensions are expected to work assuming it doesn't depend on MRI specific object and/or interpreter internals.
The Rubinius JIT performance is quite good, sometimes faster than MRI and sometimes slower. Rubinius generally executes Ruby code very fast compared to MRI. Since the majority of the Ruby Core is implemented in Ruby, rather than C as in MRI, code that depends heavily on Array, Hash, String, etc. may run slower in Rubinius. As the JIT improves so does overall performance of your code under Rubinius.
-
Thread safety. Rubinius intends to be thread-safe so you could embed more than one interpreter in a single application.
-
Clean. Readable Ruby code that is easy for users to understand and extend.
-
Reliable. Rock-solid code, with the help of Valgrind to verify correctness.
-
Modern. Bringing modern research in virtual machines, garbage collectors, and compilers to the Ruby programming language.
Please file issues for bugs or problems that you encounter at the issue tracker. The issue tracker is: http://github.com/evanphx/rubinius/issues.
The Rubinius team welcomes contributions.
Run rake docs
and see the contributing page.
Rubinius uses the BSD license. See LICENSE for details.