Hi! I'm Avdi Grimm, and this is my software development blog. More...
Books and Screencasts
Small plates of gourmet Ruby code.
32 Patterns for joyful coding.
The Making of Cowsays.com
Watch me build an app in Sinatra and Rails
Objects on Rails
A developer notebook on applying classic Object-Oriented principles to Ruby on Rails projects.
The definitive guide to exceptions and failure handling in Ruby.
- Emacs Reboot
- RubyTapas Samples
- Smalltalk Best Practice Patterns
- Study Notes
- Stuff Worth Buying
- Stupid Ruby Tricks
Category Archives: Howto
I can fetch a JSON list of subscribers like this: curl -u $API_LOGIN:$API_PASSWORD https://example.org/subscribers Then there’s jq, which is basically AWK for JSON. The following invocation simply breaks a top-level JSON array into an object per line. cat subscribers.json | … Continue reading
Lately I’ve been handling configuration entirely through environment variables for my apps, as the 12 Factor App recommends, and I can’t recommend this approach enough. As a constraint it helps me think about what parts of a given app actually need to … Continue reading
I’ve been trying to use Benoit Chesneau’s hackney library to hit the Wistia API from an Elixir program. Between the fact that hackney is still under rapid development, and the fact that I’m not great at reading Erlang code, it’s … Continue reading
So my Rakefile kept telling me RSpec wasn’t installed. begin require ‘rspec/core/rake_task’ RSpec::Core::RakeTask.new(:spec) task :default => :spec task :spec => :dotenv rescue LoadError warn “RSpec unavailable; spec task not defined” end $ rake spec RSpec unavailable; spec task not defined … Continue reading
I recently had reason to submit a one-character documentation fix to Ruby. I know submitting a patch to a high-profile project can feel intimidating, so I recorded the process to show just how straightforward it is.
I just installed Elixir and there were one or two non-obvious points. Elixir requires Erlang OTP 16, and the Ubuntu package repos contain release 15. So the Ubuntu Erlang packages won’t cut it. Instead, install Erlang from the Erlang Solutions … Continue reading
A bunch of people have asked about my screencasting process for RubyTapas. My process is a work in progress that I frequently iterate on, so this is really just a snapshot of my process as of January 2013. I don’t … Continue reading
Configuring Omniauth for GitHub authentication is easy enough. But I needed to optionally add extra permissions to the authentication token. I eventually figured it out, but since I had to piece the steps together from various sources, I thought I’d … Continue reading