jQuery promises: done() and then() are not the same

jQuery done() and then() differ in promise chaining: then() waits for returned promises, while done() ignores them and can resolve too early.

Nokogiri: How to parse large XML files with a SAX parser

Large XML imports can exhaust RAM with Nokogiri’s DOM parser; SAX parsing streams data and avoids building the full tree in memory.

Geordi 6.0.0 released

Geordi 6.0.0 keeps geordi commit running when some projects are inaccessible and drops VNC browser support and @solo serial execution.

Using StaticMatic for static pages

Build static pages with Rails-like comforts such as HAML, SASS, helpers and partials, then compile everything to plain HTML and CSS.

Enable NewRelic monitoring [for Rails] on specific hosts only

NewRelic monitoring can be restricted to selected Rails hosts by checking the current machine name before enabling monitor_mode.

Memcache: Your cache node may degenerate over time, check your settings

Memcache nodes can degrade after long runtimes as slab allocation becomes tuned to stale access patterns, increasing evictions and lowering hit rates.

vagrant < 2.2.9: handle conflicting host only adapter

Starting an existing vagrant up can fail when VirtualBox host-only networks conflict over DHCP settings. Versions before 2.2.9 need a Vagrantfile workaround.

Semantic HTML

HTML semantics improve readability, accessibility, and parser interpretation by matching elements to meaning, while HTML5 sectioning and text-level elements add structure and built-in behavior.

Giving a presentation with a dual screen layout on linux

Dual-screen presentations on Linux can keep speaker notes or a projector preview visible without cloning displays. x11vnc and a VNC viewer provide a local preview of the second screen.

Resolving Angular not updating an image src when ng-src is empty

Angular ngSrc leaves src unchanged when the bound value becomes empty; using //:0 forces an invalid blank image source so the browser clears it.

How to use cookies with curl

Curl sends and stores no cookies by default; -c and -b let you save, reload, or manually supply them for repeated requests.

Using Thin for development (with SSL)

Local SSL development with Thin avoids mixed-content and redirect issues while testing force_ssl on localhost using a self-signed certificate and separate HTTP and HTTPS ports.

Reverse-proxying web applications with nginx

Apache can be awkward for reverse proxying, especially with Digest Authentication and HTTPS passthrough; nginx offers a simpler setup for forwarding requests to another host.

mysql2 and older ruby versions

mysql2 0.3.13 can fail to compile on older Ruby 1.9.3 patch releases in rvm, causing an undefined symbol error; pinning 0.3.11 avoids the issue.

Howto: Require a gem that is not in Gemfile

LoadError occurs when a Ruby gem is required outside Gemfile or .gemspec; adding its install path to $: allows temporary loading for debugging.

Accessing Rails config in webpack(er)

Rails secrets and other configuration values can be read inside webpack bundles with rails-erb-loader, enabling environment-specific client-side settings without hardcoding them.

Jasmine: Testing AJAX calls that manipulate the DOM

AJAX DOM updates are hard to test when requests are asynchronous and the target element is missing. jasmine-ajax, jasmine-fixture, and done make network mocking and DOM setup possible.

Use SSL for Amazon RDS / MySQL (and your Rails app)

Encrypted connections between Rails and Amazon RDS MySQL protect sensitive data in transit. mysql and database.yml can be configured to require SSL end to end.

Fix slow specs using SOLR

Specs can stall for 30+ seconds when SOLR connections are left open and the pool is exhausted. Lowering the old-connection timeout reduces the delay.

How to fix: Gems are unavailable although they are installed

Rails or Rake can report missing gems even when they are installed; wrong Bundler configuration or release-directory leftovers often redirect gem lookup to the wrong place.

Unpoly 2: Don't try to download files through AJAX requests

AJAX downloads fail because browsers try to render files instead of saving them. Exclude download links from Unpoly link handling and use Content-Disposition: attachment or download.

Plotting graphs in Ruby with Gruff

Ruby charting library for Rails that generates PNG graphs with themes, multiple series, and automatic sizing for large datasets.

rails/turbolinks

Speeds up navigation by keeping the page alive between link clicks, avoiding repeated JavaScript and CSS recompilation while replacing the body and title.

net-ssh and openssl-3.0.0

Ruby 3.1 with openssl-3.0.0 can break net-ssh 6.1.0 on Ubuntu 22.04, causing Capistrano deploy failures and signature verification errors.