Our development process makes us deploy very often. As the number of releases grows, junk clogs up the hard drive...
When you need to find out in which kind of spec you are during run-time, it's definitely possible...
git shortlog -s -n [commit-range] -n, --numbered Sort output according to the number of commits per author
Option 1: Creating a self-signed certificate with the openssl binary As igalic commented on this gist. openssl req -new...
This trick might be useful to implement more complicated directives in AngularJS. I needed it to do drag'n'drop...
Rails gives you migrations to change your database schema with simple commands like add_column or update. Unfortunately these commands...
Be careful with the Active Record where method. When you accidentally pass an empty array to the where method using...
In specs, the session never persists but is always a new object for each request. Data put into the session...
Find out in this short guide, how to horizontally center a absolute positioned container with CSS. Note: We have a...
view_context.helper_method('args') Rails 2 ApplicationController.helpers.helper_method('args') Also see How to use helper methods inside a model...
The way Rational#to_s works on Ruby has changed from Ruby 1.9 on. Here is how to get the...
Unfortunately, Capybara does not offer a switch to disable cookies in your test browser. However, you can work around that...
Rails flashes (FlashHash) track a list of used keys, which is not respected when comparing flash hashes.
Rails understands a :limit options when you create columns in a migration. Its meaning depends on the column type, and...
Sometimes it seems a favicon does not work because your browser displays an old version or (in case of local...
calc() lets you mix CSS units. Ever wanted to give an element "the container's width minus 20px on each...
tl;dr: Do not use merge! for session hashes. Use update instead. Outline Let's assume you're modifying the...
Don't Google this, you will lose all will to live. Instead use Object#isEqual() from Lodash or Underscore.js:
MongoMapper is a MongoDB adapter for Ruby. We've forked it so it works for Rails 2.3.x applications running...
If you need to capture signatures on an IPad or similar device, you can use Thomas J Bradley's excellent...
If you have an integer and want to use it to represent an element's position (like "1st" for 1...
validates_uniqueness_of is not sufficient to ensure the uniqueness of a value. The reason for this is that in...
Calling bundle update GEMNAME will update a lot more gems than you think. E.g. when you do this...
Awesome color schemes for RubyMine, Sublime Text 2 and other editors. To install the themes into your Rubymine, copy intellij...