Git: Issues with Gemfile.lock
A stubborn Gemfile.lock that resists git checkout, git reset --hard, or git stash is often caused by Rails Spring rewriting the file.
Instant Markdown previews from Vim
Live Markdown preview in the browser for Vim, with GitHub-flavored syntax and automatic updates on every key press.
Exclusive cronjobs with flock and whenever
Prevent overlapping cron executions by wrapping a job in flock and using whenever to skip locked runs instead of waiting.
MutationObserver
Watch a DOM for insertions, removals, and attribute updates without polling, using MutationObserver to react immediately to structural changes.
ne, the nice editor
Command-line text editor with syntax highlighting and menu support, aimed at users who want a simpler alternative to vim and a possible nano replacement.
How to fix: RubyMine occasionally no longer accepts keyboard input
RubyMine and other IntelliJ IDEs can stop accepting keyboard input while the mouse still works, often due to IBus on Ubuntu. Launch-time environment tweaks can restore typing.
CSS Fontstack: An overview of web/web safe font support
Web safe fonts rely on preinstalled system typefaces, with font stacks providing similar fallbacks across platforms. CSS3 web fonts are an alternative when custom typography is needed.
Case Study: Analyzing Web Font Performance
Web font loading can delay first paint and cause FOIT, especially on slow connections. Delivery choices, fallback handling, and reduced font variants improve perceived performance.
IFrame Resizer
JavaScript library for iframes that automatically resize to fit embedded content, reducing scrollbars and extra whitespace.
get haproxy stats/informations via socat
HAProxy exposes runtime status through a Unix socket; socat can query version, connections, backend and frontend statistics, errors, and open sessions.
what to do if nova's iptables rules are missing
OpenStack hosts can lose iptables filter rules after a reboot while NAT remains active, often when nova services start in the wrong order. Restarting nova-compute usually repopulates the missing rules.
ping with timestamps
Timestamp each ping reply to correlate network latency with exact times and log connectivity events more easily.
How to deal with "invalid %-encoding" error in application for malformed uri
Malformed request URIs can raise invalid %-encoding and break the app before routing. A middleware can return 400 Bad Request instead of ArgumentError or ActionController::BadRequest.
Gemspecs must not list the same gem as both runtime and development dependency
Duplicating a gem in both runtime and development dependencies breaks gemspec validation and can make Bundler ignore the package. Put test-only version pins in the Gemfile instead.
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.
Ruby: How to update all values of a Hash
Update every entry in a Ruby Hash with a concise merge! trick when each key needs a new computed value.
Latency Numbers Every Programmer Should Know
Common I/O operations differ by orders of magnitude, making hardware latency easy to underestimate and performance bottlenecks hard to diagnose.
PostgreSQL: Expanded display and other command line features
\x enables expanded query output in PostgreSQL, making wide SELECT * results readable on the command line.
AngularJS: How to force Content-Type on GET and DELETE requests
AngularJS strips Content-Type from blank-body GET and DELETE requests, which can break APIs that require it. Decorating $httpBackend can restore the header selectively.
Shrine - A file upload toolkit
CarrierWave is no longer maintained, and Shrine offers a maintained alternative for file uploads.
Thunderbird: How to compose an HTML e-mail (when plain-text messages are your default)
HTML e-mails can still be needed even when plain text is the default. In Thunderbird, holding Shift while clicking compose or reply opens a message in HTML format.
Designing a landing page that sells
Iterative landing page design improves conversion by refining a single page through multiple visual and content variations.
Remove Rubygems deprecation warnings
Rubygems deprecation warnings can clutter terminal output when they cannot be fixed. Setting Deprecate.skip and Gem::Deprecate.skip in the Gemfile suppresses them.
Count number of existing objects in Ruby
Count live Ruby objects in the current process using ObjectSpace to inspect memory use and object distribution.