Posts
All the articles I've posted.
-
Formatting ActiveSupport::Duration Objects in Rails
Updated:Learn how to format ActiveSupport::Duration objects into concise, human-readable strings with locale support using the duration_in_words gem.
-
WeakMaps in JavaScript
Updated:WeakMaps allow objects to be used as keys, offering memory efficiency and encapsulation—ideal for private data storage and avoiding memory leaks.
-
Module Functions in Ruby: module_function vs extend self
Updated:In Ruby, modules can provide both namespacing and mixin functionality. Learn how to define module-level functions using module_function and extend self, and the differences between them.
-
Magic Comments in Ruby
Updated:Ruby supports file-level 'magic comments' that instruct the interpreter—most famously for source encoding, but also for freezing strings, shareable constants, and indentation warnings.
-
Working with HTTP Headers in Rails
Updated:Learn how to safely extract external HTTP headers in Rails while filtering out internal Rack and Rails environment variables.
-
Git: Revert an Updated File
How to remove an updated file from a pull request without deleting the file itself — ensuring your changeset stays clean and focused.
-
Managing Multiple SSH Keys in Git and SSH Config
Updated:Learn how to manage multiple SSH keys for personal, work, and client projects using ssh-agent, ssh config, and gitconfig conditionals.
-
Creating Python Virtual Environments
Updated:Learn how to create and use Python virtual environments with venv to isolate dependencies and manage multiple projects cleanly.
-
Fixing Homebrew & Zsh Issues After macOS Upgrades
Updated:Upgrading macOS often breaks command-line setups. Here’s how I fixed issues with Homebrew, Zsh, and oh-my-zsh during the Big Sur upgrade—steps still useful for modern macOS versions.
-
How to Use Forked NPM Dependencies
Updated:When an NPM package is missing a feature or has a blocking bug, point your project at a maintained fork via a Git URL—plus modern alternatives like patch-package and overrides.