Home Link

Hello, my name is Brett Terpstra, and it’s nice to meet you. Elegant solutions to complex problems. Curious?

Posts Tagged ‘url shortener’

Apr 28
2010

I’m fascinated by http://to. It’s a url shortener with no TLD. Some browsers, and apparently some DNS setups, don’t like the urls it creates (they want a .com or .org or anything at the end), so it’s not exactly in heavy usage. Still, I wish they had an API. In lieu of that, here’s a quick Ruby script that will run on a stock OS X install as a System Service. It’s so simple that I’m not even going to package it up… It’ll be a good chance to show the steps for creating your own utilities using Snow Leopard Services:

require 'net/http' require 'cgi'input = STDIN.read http = Net::HTTP.new('to.')

Entries (RSS) and Comments (RSS), or Subscribe by Email