Controller responses often include Javascript code that contains values from Ruby variables. E.g. you want to call a Javascript function...
By default, Google Analytics tracks the current URL for every request. Sometimes you will want to track another URL instead...
In your ~/.gitconfig: [core] editor=nano
So you probably see the following error trace within your Passenger log file if you got here:
zClip is a lightweight jQuery "copy to clipboard" plugin built using the popular Zero Clipboard library. This plugin uses an...
A small library to provide the Rails I18n translations in Javascript clients.
An association defined with has_many :through will return the same record multiple times if multiple join models for the...
xterm by default uses black text on white background. To change that to something like "light gray on black", do...
This is for you if Passenger gives you the following useless error message. Passenger encountered the following error:\ The application...
You can change which branches will be pushed when saying git push. Our recommendation is to set it to current...
The default behavior of Calc is that when you paste cells from the clipboard, it overwrites whatever cells occupy the...
If you cannot install the gem 'RedCloth' via bundle install you might want to try the following. Specifying extra build...
Geordi, our collection of command line tools, has been extended by another command deploy-to-production. This script encapsulates the...
You can define what will be printed by checking View -> Preview Page Breaks and then moving around the blue borders...
After installing Bundler 1.1 you will get the following warning when running tests: WARNING: Cucumber-rails required outside of env.rb...
How to get a backtrace from a running Ruby process: Ruby 2.6 # First, find out the PID of your Ruby...
Solution to share a todo.txt file over Dropbox and make it editable on Android und iOS devices. Also comes with...
validates_acceptance_of :terms only works if terms is set to a value. The validation is skipped silently when terms...
When you create a new branch and push it to origin, you won't be tracking it. This means a...
TL;DR {} binds stronger than do … end (as always in Ruby, special characters bind stronger than words) Demo
This card needs to be updated for Rails 3+. Since there is no --debugger flag you need to run:
You won't usually have to do this. It's OK to route all formats to a controller, and let...
When talking to your MySQL server via a mysql shell, you can terminate queries by ; or \G -- the latter gives...
The following two hints are taken from Github's Ruby style guide: If your regular expression mentions a lot of...