http://guides.rubyonrails.org/migrations.html
- add_column
- add_index
- change_column
- change_table
- create_table
- drop_table
| !!! strict | |
| !!! XML | |
| %html | |
| -# Self closing tags | |
| %img{:src => "happy.jpg"}/ | |
| %div.myclass | |
| .myclass1 |
http://guides.rubyonrails.org/migrations.html
| <snippet> | |
| <!-- put this file in /packages/User/<Folder Name>/console_log.sublime-snippet then restart your Sublime Text 2 --> | |
| <content><![CDATA[console.log($1);$0]]></content> | |
| <tabTrigger>conl</tabTrigger> | |
| <scope>text.html,source.js</scope> | |
| <description>console.log()</description> | |
| </snippet> | |
| <snippet> | |
| <!-- put this in another file /packages/User/<Folder Name>/console_dir.sublime-snippet then restart your Sublime Text 2 --> |
| drush php-eval 'node_access_rebuild();' |
You can break these rules if you can talk your pair into agreeing with you.
| source "https://rubygems.org" | |
| gem "sinatra" | |
| gem "tilt-jbuilder", ">= 0.4.0", :require => "sinatra/jbuilder" | |
| gem "hashie" |
| # SSL self signed localhost for rails start to finish, no red warnings. | |
| # 1) Create your private key (any password will do, we remove it below) | |
| $ openssl genrsa -des3 -out server.orig.key 2048 | |
| # 2) Remove the password | |
| $ openssl rsa -in server.orig.key -out server.key |
| RSpec::Matchers.define :translate_to do |key, options| | |
| match do |actual| | |
| @expected = I18n.t(key, options) | |
| @failure = nil | |
| @failure ||= :bad_actual if actual.start_with?('translation missing:') | |
| @failure ||= :bad_expected if @expected.start_with?('translation missing:') | |
| @failure ||= :no_match if @expected != actual | |
| @failure.nil? | |
| end |
Updated for Rails 4.0.0+
Set up the bower gem.
Follow the Bower instructions and list your dependencies in your bower.json, e.g.
// bower.json{
| git rebase --interactive HEAD~2 | |
| # we are going to squash c into b | |
| pick b76d157 b | |
| pick a931ac7 c | |
| # squash c into b | |
| pick b76d157 b | |
| s a931ac7 c |