Skip to content

Installation

Albert Álef edited this page Feb 3, 2026 · 2 revisions

Installation

Using Bundler (recommended)

Add RubyShell to your Gemfile:

gem 'rubyshell'

Then run:

bundle install

Or add it directly with:

bundle add rubyshell

Direct Installation

gem install rubyshell

Requiring the Gem

require 'rubyshell'

This extends Kernel with the sh method, making it available everywhere in your Ruby code.

Verifying Installation

require 'rubyshell'

sh do
  puts pwd
end

If you see your current directory printed, RubyShell is working correctly.


Next: Basic Usage

Clone this wiki locally