Install RubyMine under Ubuntu
RubyMine on Ubuntu can be installed as a snap with automatic updates or set up manually from the legacy archive. Configuration stays in ~/.config/JetBrains/RubyMine<version> with classic confinement.
Installing Nokogiri
Because Nokogiri needs to be compiled and dynamically linked against both libxml2 and libxslt, it has gained a reputation for being complicated to install. Let’s wrassle this little myth to the ground, shall we?
Counters for Partials
When rendering a partial with the :collection option, you are automatically provided with a counter variable inside the partial template.
Hunt down that elusive debug message in Ruby
Trace stray puts and p output in Ruby by inserting a temporary hook that prints a backtrace for a chosen message, then remove it after cleanup.
Disable automatic e-mail checking in Thunderbird 3
Reduce attention-grabbing interruptions by stopping Thunderbird 3 from checking mail automatically at startup, on intervals, or via server IDLE notifications.
Take care when joining and selecting on scopes
Complex joined queries can return ActiveRecord objects with the wrong primary key when select pulls columns from multiple tables. Restricting the projection to users. preserves the correct id.
Manipulate an array attribute using multiple check boxes
Multiple check boxes can bind to an array-backed virtual attribute, making tag selection and validation-safe form round trips work with one value per option.
Use the back button in Cucumber
Navigate to the previous page in Cucumber feature tests when browser history is unavailable, using the HTTP referrer in Capybara or Webrat.
Thoughtbot's experiences with headless Javascript testing
Selenium has been the siren song that continually calls out to us. Unfortunately, in practice we’ve been unable to get Selenium to run reliably for real applications, on both developers machines and on the continuous integration server. This failure with Selenium has caused us to search for alternative solutions
Change commit messages of past Git commits
Change the message of the latest unpushed Git commit with git commit --amend, or rewrite older unpushed commit messages with interactive rebase.
Test a gem in multiple versions of Rails
Rails gems that must support several framework releases need separate test apps per version. Shared code and specs reduce duplication while keeping version-specific coverage.
Test that a select option is selected with Cucumber
Checks whether a form dropdown has a preselected value in HTML using Cucumber step definitions for Capybara or Webrat.
Useful collection of Sass mixins
Sass mixins for cross-browser styling reduce code and enable CSS3PIE support in Internet Explorer 8 and earlier.
Enable SSL for Pivotal Tracker
You should never transmit sensitive data without encryption. Being logged in somewhere constitutes transmitting sensitive data.
For Pivotal Tracker:
- Make sure you set "Always Use HTTPS" under "My Profile".
- As you can not rely on every member of a project to have this enabled, you should also tick "Use HTTPS" on the settings page of each project.
Trigger an event with Javascript
Synthetic DOM events are awkward across browsers, especially for clicks and custom events. jQuery, Prototype, and Element.fire() offer simpler ways to simulate them.
kangax's protolicious - GitHub
Added utility methods for the Prototype Javascript framework.
Cross-browser height and line-height
Odd line-height values render inconsistently across major browsers; using even values and a Sass mixin helps keep block element sizing stable.
Retrieve the total number of records when paginating with will_paginate
will_paginate pagination can hide the full result size; total_entries returns the pre-pagination record count, but may require a slow second query.
Keep Pidgin up to date
If your pidgin IM fails to connect to ICQ, you may need to update it. The ubuntu default sources are usually outdated.
Just follow the instructions 1-4 and 1-3 on the page linked below.
Making SSL connection work
If you can not connect using SSL, open up the account settings and enable "clientLogin". Also, your Server should be set to slogin.icq.com.
Making AJAX Applications Crawlable
This document describes an agreement between web servers and search engine crawlers that allows for dynamically created content to be visible to crawlers. Google currently supports this agreement. The hope is that other search engines will also adopt this proposal.
Problems with Rails 3 Remote Links and Forms Using jQuery .live() in IE
There is a problem with AJAX response handling for Rails 3 remote links and forms in Internet Explorer. This problem affects applications still using jQuery 1.4.2.
Git: Stash unstaged changes
Stash only unstaged changes in Git with git stash -k; use -u to include new files, and keep the working tree clean before git stash pop.
Bookmarklet to generate a commit message with Pivotal Tracker story ID and title
Generate commit messages from selected Pivotal Tracker stories with ID and title for traceable git history.
scribd's flash_heed at master - GitHub
Fixes all Flash elements on a page so that they heed DOM stacking order