{"id":13524038,"url":"https://github.com/mhartl/rails_tutorial_sublime_text","last_synced_at":"2026-03-10T23:36:22.105Z","repository":{"id":2911167,"uuid":"3920453","full_name":"mhartl/rails_tutorial_sublime_text","owner":"mhartl","description":"Sublime Text 2 setup used in the Ruby on Rails Tutorial","archived":false,"fork":false,"pushed_at":"2016-02-27T16:35:17.000Z","size":31,"stargazers_count":714,"open_issues_count":0,"forks_count":111,"subscribers_count":59,"default_branch":"master","last_synced_at":"2025-04-01T02:35:18.258Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://railstutorial.org/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mhartl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-04-03T17:16:06.000Z","updated_at":"2024-11-01T00:28:54.000Z","dependencies_parsed_at":"2022-09-12T05:41:27.064Z","dependency_job_id":null,"html_url":"https://github.com/mhartl/rails_tutorial_sublime_text","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mhartl/rails_tutorial_sublime_text","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhartl%2Frails_tutorial_sublime_text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhartl%2Frails_tutorial_sublime_text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhartl%2Frails_tutorial_sublime_text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhartl%2Frails_tutorial_sublime_text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mhartl","download_url":"https://codeload.github.com/mhartl/rails_tutorial_sublime_text/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mhartl%2Frails_tutorial_sublime_text/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30362123,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T21:41:54.280Z","status":"ssl_error","status_checked_at":"2026-03-10T21:40:59.357Z","response_time":106,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T06:01:06.412Z","updated_at":"2026-03-10T23:36:22.074Z","avatar_url":"https://github.com/mhartl.png","language":"Python","funding_links":[],"categories":["Python","Extensions"],"sub_categories":["Ruby Profile"],"readme":"# Rails Tutorial Sublime Text setup\n\nThese are the steps needed to set up [Sublime Text 2](http://www.sublimetext.com/) as in the [Ruby on Rails Tutorial](http://ruby.railstutorial.org). 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.)\n\n## Command-line command\n\nOn OS X, you can set up `subl` as a command-line command like this:\n\n    $ ln -s \"/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl\" ~/bin/subl\n\nThis assumes that there is a `~/bin` directory on your executable path. If that isn't the case, follow the instructions on [this Stack Overflow thread](http://stackoverflow.com/questions/13655343/sublime-text-2-os-x-command-line).\n\nOn Linux (especially Ubuntu), the command is similar to OS X; the paths differ and you must use `sudo`, which is required because ordinary users don't have permission to write to `/usr/bin`:\n\n    $ sudo ln -s ~/Applications/Sublime\\ Text\\ 2/sublime_text /usr/bin/subl\n\nAlternatively, add an alias to `sublime_text` in your `~/.bashrc` file.  This method doesn't require `sudo`. But it assumes you are using `bash`. There are similar methods available for other shells. Google is your friend.\n\nUse any editor like gedit or vim to open `~/.bashrc`.\n\n    $ gedit ~/.bashrc\n\nAdd `alias subl='~/Applications/Sublime\\ Text\\ 2/sublime_text'` at the end of the file. Save and exit.\n\n(You may have to replace the path to `sublime_text` with the correct one for your system.)\n\nOn Linux Mint, take a look at [Install Sublime Text 2 in Linux Mint](http://www.codeproject.com/Articles/582849/InstallingplusSublimeplusTextplus-plusonplusLinuxp).\n\nOn Windows, you can simply double-click the application icon. The setup at the command line depends on which shell you use; see if one of the techinques at the [Stack Overflow discussion on Sublime Text from Command Line (Win7)](http://stackoverflow.com/questions/9440639/sublime-text-from-command-line-win7) works for you. You might also want to check out the video [Easily Open Files from Windows Command Prompt with Sublime Text 2](http://youtu.be/zcUpdw5_uSY) (I suggest changing `st2` to `subl` to be consistent with the instructions for the other platforms).\n\n## Basic configuration\n\nOpen up Sublime Text and use the `View` menu to modify the following settings:\n\n`View \u003e Hide Minimap`\n\n`View \u003e Side Bar \u003e Hide Side Bar`\n\n`View \u003e Layout \u003e Columns: 2`\n\n## Copy auxiliary files\n\n    $ cd /tmp\n    $ git clone https://github.com/mhartl/rails_tutorial_sublime_text.git\n    $ cp -r rails_tutorial_sublime_text/* \\\n            ~/Library/Application\\ Support/Sublime\\ Text\\ 2/Packages/User/\n\nSetup on Linux is similar, but with a different target directory for `cp`:\n\n    $ cp -r rails_tutorial_sublime_text/* \\\n            ~/.config/sublime-text-2/Packages/User/\n\nOn Windows, the target directory is as follows:\n\n    $ cd /tmp\n    $ git clone https://github.com/mhartl/rails_tutorial_sublime_text.git\n    $ cp -r .\\rails_tutorial_sublime_text\\* \\\n            '~\\AppData\\Roaming\\Sublime Text 2\\Packages\\User'\n\nNote: If using Windows Vista, 7, or 8, you should first copy all the folders and files from the remote repo into your local temporary folder located at `C:\\Users\\User\\AppData\\Local\\Temp`. Then proceed to move these same files to `C:\\Users\\User\\AppData\\Roaming\\Sublime Text 2\\Packages\\User`.\n\n## Install Sass syntax highlighting\n\nInstall [Package Control](https://sublime.wbond.net/) and then go to `Preferences \u003e Package Control`. Select `Install Package` and then select the Sass package.\n\n## Set up the theme\n\nSelect `Preferences \u003e Color Scheme \u003e User \u003e Railscasts`\n\n## Install the Rails Tutorial snippets\n\n[https://github.com/mhartl/rails_tutorial_snippets](https://github.com/mhartl/rails_tutorial_snippets)\n\n## Install Sublime Text Alternative Auto-completion\n\n[https://github.com/alexstaubo/sublime_text_alternative_autocompletion](https://github.com/alexstaubo/sublime_text_alternative_autocompletion)\n\n## Install SublimeERB\n\n[https://github.com/eddorre/SublimeERB](https://github.com/eddorre/SublimeERB)\n\n## Install RubyTest\n\nFollow [https://github.com/maltize/sublime-text-2-ruby-tests](https://github.com/maltize/sublime-text-2-ruby-tests), or install RubyTest using [Package Control](https://sublime.wbond.net/).\n\nGo to `Preferences \u003e Package Settings \u003e RubyTest \u003e Settings - User` and paste in the following code:\n\n```javascript\n{\n  \"check_for_rbenv\": true,\n  \"check_for_rvm\": true,\n  \"check_for_bundler\": true\n}\n```\n\nIf you want the \"Red\" part of \"Red-Green-Refactor\" to be truly red, edit the file `\"TestConsole.hidden-tmTheme\"` in the `Library/Application\\ Support/Sublime\\ Text\\ 2/Packages/RubyTest` directory:\n\n    $ cd ~/Library/Application\\ Support/Sublime\\ Text\\ 2/Packages/RubyTest\n    $ subl TestConsole.hidden-tmTheme\n\nIn that file, change\n\n    \u003cstring\u003e#FF1493\u003c/string\u003e\n\nto\n\n    \u003cstring\u003e#FF0000\u003c/string\u003e\n\nYou may have to restart Sublime Text 2 to activate the change.\n\nIf you ever get the error\n\n    /bin/sh: rspec: command not found\n\nyou can simply quit Sublime Text and then restart it by typing\n\n    $ subl\n\n(with no dot).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmhartl%2Frails_tutorial_sublime_text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmhartl%2Frails_tutorial_sublime_text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmhartl%2Frails_tutorial_sublime_text/lists"}