Sublime Text 2 setup used in the Ruby on Rails Tutorial
Switch branches/tags
Nothing to show
Pull request Compare This branch is 40 commits behind mhartl:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

Rails Tutorial Sublime Text setup

These are the steps needed to set up Sublime Text 2 as in the Ruby on Rails Tutorial. Instructions are for OS X; Linux and Windows users should make substitutions as necessary. (This may require web searches. Please let me know if you find something that you think should be included here.)

Command-line command

On OS X, you can set up subl as a command-line command by following the Sublime Text 2 instructions for the OS X command line:

$ ln -s "/Applications/Sublime Text" ~/bin/subl

This assumes that ~/bin is in your path.

For other platforms, either double-click the application icon or search around to learn how to set a command-line command. (Please email me if you figure it out for either Windows or Linux and I'll post the results here.)

Basic configuration

Open up Sublime Text and use the View menu to modify the following settings:

View > Hide Minimap

View > Side Bar > Hide Side Bar

View > Layout > Columns: 2

Copy auxiliary files

$ cd /tmp
$ git clone
$ cp -r rails_tutorial_sublime_text/* \
        ~/Library/Application\ Support/Sublime\ Text\ 2/Packages/User/

Setup on Linux should be similar, but with a different target directory for cp.

On Windows, the target directory is as follows:

$ cd /tmp
$ git clone
$ cp -r .\rails_tutorial_sublime_text\* \
        '~\AppData\Roaming\Sublime Text 2\Packages\User'

Install Sass syntax highlighting

Follow the instructions at sublime-text-haml-sass.

Set up the theme

Select Preferences > Color Scheme > User > Railscasts

Install the Rails Tutorial snippets

Install Sublime Text Alternative Auto-completion

Install SublimeERB

Install RubyTest

Follow Then edit the file "Theme - Default/Widget.sublime-settings" in the Library/Application\ Support/Sublime\ Text\ 2/Packages directory:

$ cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages
$ subl "Theme - Default/Widget.sublime-settings" 

In that file, change

"color_scheme": "Packages/Theme - Default/Widgets.stTheme"


"color_scheme": "Packages/User/CustomTestConsole.tmTheme"