When your app composes tweets: Dealing with metadata

For those who don’t know, Twitter converts every URL to its own “t.co” shortener URL. So no matter how short or long your original URL is, the t.co URL will end up as a fixed character length, and that character...

A simple way to speed up Vim Ctrl-P plugin: Delegate to Ag

Ctrl-p is “Intellisense for Vim”, allowing you to quickly jump to a file by searching for a few letters or even fancy camel-case type searches. (e.g. find article_editor.rb by searching for “ae”). However, doing all this requires it to maintain...

Installing Android Marshmallow – quick gotcha notes

What the various guides often omit. Run android-sdk/tools/android and update platform-tools The oem unlock setting on phone kept reverting. But “fastboot oem unlock” fixed it. Ensure “adb devices” shows the device Ensure “Device State” on phone shows as UNLOCKED “cannot...

Speeding up Rails tests with Spring

I found Rails tests were running slow, these things helped. Instrumenting application.rb First, I added some logging to application.rb [ruby] def logg(m) puts “#{DateTime.now} #{m}” end logg ‘require boot’ require File.expand_path(‘../boot’, FILE) logg ‘done’</code> [/ruby] The main bottleneck was bundling...