Tagged with google

Read standard input using Objective-C

2009-12-06 11:50:08

On a couple of occasions now I've wanted to read from STDIN into an Objective-C command line tool, and both times I've had to hunt quite a bit to find the answer because nothing shows up in google for the search terms I used. "Objective-c read from stdin" and "objc read stdin" both turn up results ranging from using NSInputStream--More--

Capitalise "ringer" on the iPhone Volume Bezel

2009-06-20 15:44:04

Backstory: Got myself a first generation iPhone second hand and unlocked it to work on my existing T-Mobile (Official iPhone network in the UK is O2.) Noticed after a week or so of owning it that when you change the volume on the phone, the bezel that comes up says "ringer" across the top. But when you have headphones plugged … --More--

Find shell commands with which

2009-04-19 15:02:04

So I have this command in my $PATH, apachectl. Because I'm on a mac and I've installed apache2 through MacPorts, the command that gets found first is my macports install in /opt. Up until now I've always known that which apachectl will find that location, but to find any other locations of apachectl I'd usually use locate and egrep… --More--

Install Mysql Gem on Leopard

2009-01-21 17:09:41

So, I keep having to reinstall mysql5 and rubygems from time to time for various reasons. I always install mysql5 through MacPorts as a dependency for the php5 port (along with various other bits for the LA*P stack). --More--


2009-01-04 09:40:59

I finally wrapped up some code I've been meaning to write for a while, its a wrapper for the Google Translate API. Its also the first serious time I've used method_missing in a class, in this case its to add methods for translating between all the various languages. --More--