It is good programming practice to Don't Repeat Yourself (or DRY). In Ruby on Rails we keep our code...

So you client has asked you to implement a row of buttons to like the URL on Facebook, Twitter and...

stackoverflow.com

If you want to have routes that are only available in tests (e.g. for testing obscure redirects), you can use...

askubuntu.com

If your XFCE renders text with overly hard, thin lines instead of smooth anti-aliased lines, you might need to...

So you're switching to PostgreSQL from MySQL? Here is some help... General hints on PostgreSQL \? opens the command overview...

Using text-transform: uppercase - especially on form labels - can cause you serious headaches in Selenium tests. Sometimes the web driver...

tjvantoll.com

Did you know you can color your line-throughs or underline, or make them wavy like spell-checkers do?

The translation method translate and its alias t have bang brothers: translate! and t!. They will raise I18n::MissingTranslationData on...

Consul 0.10.0 now allows multiple power mappings for nested resources. When using nested resources you probably want two power

apidock.com

When you're writing migrations that do more than changing tables (like, modify many records) you may want some output...

In Rails 5 you can say: ApplicationController.render( :template => 'users/index', :layout => 'my_layout', :assigns => { users: @users } ) If a Request Environment is...

Simply give the select helper an option :disabled, passing either a single value or an array. You need to specify...

For Capybara, use this step: Then /^"([^"]*)" should be a disabled option for "([^"]*)"(?: within "([^\"]*)")?$/ do |value, field, selector| with_scope(selector...

Exception notifications contain a lot of information: Backtraces, HTTP headers, etc. exception_notification tries its best to format this wall...

We tend to use database transactions as a magic bullet to get rid of all our concurrency problems. When things...

Did you know you can do in-place batch processing with plain ruby? The following script will in-place replace...

You can use xmllint to pretty-print ugly XML files on your terminal. Just say: xmllint --format file.xml

linuxsa.org.au

Here is a good explanation for zombie processes. Quote: If you have zombie processes it means those zombies have not...

makandra dev
rakeroutes.com

Put the attached files into your home directory and enjoy. .irbrc defines interesting_methods, which is essentially all methods without...

If you want a widget for awesome that runs a command regularly (every X seconds) and puts the output into...

This trick might be useful to implement more complicated directives in AngularJS. I needed it to do drag'n'drop...

We have often felt the pain where our models need to serve too many masters. E.g. we are adding a...

Note: This technique is confusing and slows down your test suite. Copy the attached code to features/support. This gets you...