Regain unused disk space from OpenStack instances

Reclaim wasted storage from oversized OpenStack qcow2 instance disks by shrinking the image after zeroing free space and recreating the file.

httpclient: A Ruby HTTP client for serious business

httpclient is more than a thin net/http wrapper: it reuses persistent connections across threads, manages cookies, and supports asynchronous requests and debug output.

Error installing gem with native extension (collect2: error: ld returned 1 exit status)

Native gem builds can fail with collect2: error: ld returned 1 exit status when required development headers or libraries are missing, such as libgmp on Debian-based systems.

Install PhantomJS under Ubuntu

PhantomJS lacks Linux binaries, making manual builds cumbersome; installing it globally with npm provides a simpler way to get the command running on Ubuntu.

Install Bower under Ubuntu

Bower can be installed on Ubuntu through npm after Node.js is available.

Installing Node.js / npm under Ubuntu with nvm (with yarn)

Node.js on Ubuntu is easier to manage with nvm, avoiding sudo for global packages and enabling per-version npm and yarn setup.

natritmeyer/site_prism

SitePrism adds a semantic Page Object Model DSL for Capybara acceptance tests, making site interfaces easier to model and query with reusable page and section objects.

Migrating legacy jQuery code to .on() and .off()

Legacy jQuery event code using bind, delegate, live, unbind and die needs upgrading to on() and off() for modern event handling.

httpbin: HTTP Client Testing Service

Generic endpoints for testing HTTP clients with slow connections, redirects, and compressed responses, useful when debugging timeout issues.

Bootstrap 4 is coming

Bootstrap 4 switches from Less to Sass, adds flexbox-based layout options and cards, and modernizes customization, JavaScript, and browser support.

Retina revolution

High-resolution JPEGs can deliver sharp images on low- and high-DPI displays while keeping compression artifacts small enough to stay unobtrusive.

DevDocs is your API Hub

Fast, searchable access to multiple API references with fuzzy matching, keyboard shortcuts, offline use, and browser installation support.

Pitfall: has_defaults on virtual attributes are nil when loaded from database, of course …

Virtual defaults disappear on persisted records, so combining them with database-backed values can raise nil errors. Model design or explicit initialization avoids the nil surprise.

Creating spheres with CSS

Using border-radius and gradients, flat circles become sphere-like shapes; animation can add a more lifelike effect.

How to update RubyGems binary for all installed rubies

Keeping RubyGems current across multiple installed Ruby versions avoids security issues, but Ruby 1.8.7 needs the last compatible release.

Native app install banners in Android, iOS

Mobile Chrome and Safari can show native install prompts for related apps, boosting app discovery through the phone's built-in UI with platform-specific requirements.

Continuous Security Testing with Devops - OWASP EU 2014

Automated security testing integrated into a BDD workflow reduces gaps between development and security review for teams shipping software continuously.

Flash-Free Clipboard for the Web

JavaScript copy-to-clipboard support is moving into browsers through document.execCommand, reducing the need for Flash-based fallback buttons.

AWS Public IP Address Ranges Now Available in JSON Form

AWS public IP ranges are available as authoritative JSON at https://ip-ranges.amazonaws.com/ip-ranges.json and change several times per week, so polling is needed.

whenever: Preview the crontab

Preview the cron syntax that whenever would install without changing the local crontab.

passenger problems with upgraded rails-app

Passenger may misdetect an upgraded Rails app as Rails 1/2 and fail to spawn it; a full Apache restart can load the new application settings correctly.

postgresql create extension without giving the application superuser rights

PostgreSQL extensions do not require application users to be superusers; create them once with a superuser account such as postgres.

include_tags with the asset pipeline

Rails asset paths depend on a leading slash when using javascript_include_tag or stylesheet_link_tag; files in /assets also need to be added to the precompile list.

List RubyGems binary version for all installed Ruby versions

Different Ruby installations can use different RubyGems versions, making it hard to compare toolchains. rbenv and RVM can print the active gem version for each installed Ruby.