Loosely ordered with the commands I use most towards the top. Sublime also offer full documentation.
| Ctrl+C | copy current line (if no selection) |
| Ctrl+X | cut current line (if no selection) |
| Ctrl+⇧+K | delete line |
| Ctrl+↩ | insert line after |
| # Default set of awesome for my rails projects. | |
| gem 'RedCloth', :lib => 'redcloth' | |
| gem 'haml' | |
| gem 'mislav-will_paginate', :lib => 'will_paginate', :source => 'http://gems.github.com' | |
| plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
| plugin 'hoptoad_notifier', :git => "git://github.com/thoughtbot/hoptoad_notifier.git" | |
| initializer 'hoptoad.rb', <<-FILE | |
| HoptoadNotifier.configure do |config| |
| <script src="https://ajax.googleapis.com/ajax/libs/chrome-frame/1.0.2/CFInstall.js"></script> | |
| <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script> | |
| <script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.18/jquery-ui.min.js"></script> |
| require "rake/testtask" | |
| Rake::TestTask.new(:test => "db:test:prepare") do |t| | |
| t.libs << "test" | |
| t.pattern = "test/**/*_test.rb" | |
| end | |
| task :default => :test |
| gem "rspec-rails", :group => [:test, :development] | |
| group :test do | |
| gem "factory_girl_rails" | |
| gem 'capybara' | |
| gem "guard-rspec" | |
| end |
| div.spawn{ | |
| background :yellow; | |
| color: #000; | |
| border: 1px solid #000; | |
| width: 25px; | |
| height: 25px; | |
| text-align: center; | |
| padding: 2px 0; | |
| position: absolute; | |
| } |
| =Navigating= | |
| visit('/projects') | |
| visit(post_comments_path(post)) | |
| =Clicking links and buttons= | |
| click_link('id-of-link') | |
| click_link('Link Text') | |
| click_button('Save') | |
| click('Link Text') # Click either a link or a button | |
| click('Button Value') |
Loosely ordered with the commands I use most towards the top. Sublime also offer full documentation.
| Ctrl+C | copy current line (if no selection) |
| Ctrl+X | cut current line (if no selection) |
| Ctrl+⇧+K | delete line |
| Ctrl+↩ | insert line after |
| source 'https://rubygems.org' | |
| gem 'rails', '3.2.9' | |
| gem 'sass-rails-bootstrap' | |
| gem 'haml-rails' | |
| gem 'jquery-rails' | |
| gem 'RedCloth' | |
| gem 'kaminari' | |
| gem 'devise' | |
| gem 'resque' |
| #environment.rb | |
| Date::DATE_FORMATS.merge!(:default => "%m/%d/%Y") |
| #! /bin/bash | |
| ### BEGIN INIT INFO | |
| # Provides: unicorn | |
| # Required-Start: $local_fs $remote_fs $network $syslog | |
| # Required-Stop: $local_fs $remote_fs $network $syslog | |
| # Default-Start: 2 3 4 5 | |
| # Default-Stop: 0 1 6 | |
| # Short-Description: starts the unicorn web server | |
| # Description: starts unicorn |