Ruby: Indent a string
Adds String#indent for padding each line, including blank lines, without introducing trailing whitespace and with optional custom indentation characters.
New cards feature: Cite other cards
Link related cards directly from the editor by searching for a card and inserting a Markdown link into the text area.
New cards feature: Github-style code blocks
Add code blocks without indentation using triple backticks, matching GitHub-style fenced code blocks for easier formatting in plain text and Markdown.
Make Capistrano use SSH Key Forwarding
Capistrano can check out code on the target server using SSH agent forwarding instead of a separate repository key. ssh_options[:forward_agent] = true enables this, but it should be used with caution.
Git: Retrieve a file from a different branch or commit
Recover a file from another branch or earlier commit without switching the whole repository. git show displays it, and git checkout restores it into the working tree.
Fix ActionController::Session::CookieStore::CookieOverflow
CookieOverflow in ActionController::Session::CookieStore means session or flash data exceeds cookie size limits, often from storing too much object data.
Use the "retry" keyword to process a piece of Ruby code again.
Ruby can re-run a rescued begin block with retry, useful for temporary failures such as unavailable remote servers; a termination condition prevents infinite loops.
Cucumber step to test that a tooltip text exists in the HTML
HTML-attribute tooltips are entity-encoded, so presence checks need decoded text or encoded matching in Capybara.
Look up a gem's version history
Check a gem’s release history to find newer compatible versions, especially when you need a Rails 2 variant of an installed library.
Fixing Graticule's "distance" for edge cases
Float rounding can make Graticule’s spherical distance calculation call acos with values slightly outside the valid range, breaking zero-distance cases.
How to customize CKEditor dialogs
CKEditor dialog tabs and fields can be adapted to fit a custom editing workflow.
How to fix a corrupt git index
Git index corruption blocks commands like git status and git pull, but uncommitted changes remain. Removing .git/index and resetting the branch restores the repository.
Mac OS X Lion (10.7.2) screws host resolution
Mac OS X Lion 10.7.2 can ignore /etc/hosts and break local name resolution, so Apache virtual hosts and Passenger settings stop working as expected.
turn.js - The page flip effect for HTML5
jQuery plugin that creates a realistic page-flip transition for HTML5 content, suitable for book- or magazine-style browsing in modern browsers.
nruth/show_me_the_cookies - GitHub
Helpers for inspecting and manipulating Capybara browser cookies in integration tests, with support for rack-test and Selenium WebDriver.
Flexible overflow handling with CSS and JavaScript
Truncates one variable-length label while keeping a second label visible on the same line, with a JavaScript fallback for browsers without the needed layout.
Use CSS "text-overflow" to truncate long texts
Single-line text can overflow its container in Rails views; text-overflow: ellipsis and white-space: nowrap produce cleaner truncation in supported browsers.
Mysql::Error: SAVEPOINT active_record_1 does not exist: ROLLBACK TO SAVEPOINT active_record_1 (ActiveRecord::StatementInvalid)
Parallel test runs can trigger missing-savepoint rollback errors when processes share a database or transactional test settings conflict.
Using Vim to repair files with incorrect character encoding/representation
Fix files whose special characters were saved with the wrong encoding, such as UTF-8 text shown as latin1 mojibake, by reopening them in Vim with the correct file encoding.
Desktop Notifications with WebKit
Chrome supports desktop pop-up notifications through WebKit's webkitNotifications API, letting websites trigger popup bubbles from JavaScript.
Test whether a form field exists with Cucumber and Capybara
Capybara and Cucumber can assert whether a labeled form control is present or absent, with step definitions needing adjustment across older Capybara versions.
Ubuntu: Reload Gnome panel while keeping user session
Restart the GNOME panel without signing out when widgets or the panel cache are stale; killall gnome-panel often brings it back automatically.
paul/progress_bar - GitHub
Simple Ruby console library for showing task progress during long-running jobs with minimal setup.
Sunspot for Solr fails with '400 Bad Request' in 'adapt_response'
Sunspot can fail with 400 Bad Request in adapt_response when Solr uses the wrong schema. Copy Sunspot’s schema.xml into Solr’s config and restart the server.