makandra dev
github.com

When you need to use diff in either some Ruby code or your Rails app, use the differ gem.

paperplanes.de

This post is not about devops, it's not about lean startups, it's not about web scale, it's...

en.wikipedia.org

Under the same origin policy, a web page served from server1.example.com cannot normally connect to or communicate with a server...

codeodor.com

Code example for implementing Cross-Origin Resource Sharing (CORS) in Rails.

The Javascript code below is a rough equivalent to the simple_format helper that ships with Rails: function simpleFormat(str...

In Rails 2, you could use link_to_remote...

...:update => 'id' to automatically replace the content of $('#id').

Below you can find the hex color codes for the Color Graphics Adapter palette which used to be popular in...

makandra dev

I've recently encountered a weird problem with specs making lots of SOLR queries using the acts_as_solr plugin...

makandra dev
martinfowler.com

A common question in IT departments is whether to provide a capability by building custom software or by buying a...

Ever wondered if there is a reverse for Rails' .each(&:to_s) idiom? Turns out there is... You probably already...

My RubyMine (and it seems like many other Java GUI applications) crashes the Compiz window decorator almost every time on...

jwz.org

An ancient essay on software design that, after 20 years, should still guide you for every line of code you...

In order to request a SSL certificate from any dealer, you usually need a CSR certificate. As both the CSR...

damieng.com

Very nice font for programming.

Copy the attached Ruby code to config/initializers, or paste it into your IRB console. You can now dump any two...

blog.jayfields.com

Deprecated ways to execute shell code in Ruby This is just a reference for legacy code. For new code, always...

When your cucumber features grow massively over time, the test execution can take a lot of time.

Capybara allows you to select DOM elements, e.g. by using field, find_field(...) or field_labeled(...): role_select = field_labeled...

makandra dev

Validations that need to access an associated object may lead to some trouble. Let's exemplify that using this example...

When deploying an application with "cap deploy" by default [1] you only deploy your code but do not run migrations...

travisonrails.com

You set a flash message and it shows up as it should. However, it is displayed again the next time...

The Edge Rider gem will define a method collect_ids on your ActiveRecord models, scopes, integer scalars and collections, which...

ActiveRecord gives you the :include option to load records and their associations in a fixed number of queries. This is...

apidock.com

Note: ActiveRecord::Base#becomes has a lot of quirks and inconsistent behavior. You probably want to use ActiveType.cast instead.