Tagged with ruby19

Defining Ruby Superclasses On The Fly

2011-12-18 01:13:14

Any rubyist that's defined a class should understand the following class definition: --More--

#to_param and keyword slugs

2011-07-05 23:13:43

Imagine you've got a blogging app and it's currently generating URL paths like posts/10 for individual posts. You decide the path should contain the post title (in some form) to make your URLs friendlier when someone reads them. I know I certainly prefer to read http://caiustheory.com/abusing-ruby-19-and-json-for-fun vs http://caiustheory.com/?id=70. (That's a fun blog post if you're into (ab)using ruby occasionally!) --More--

Abusing Ruby 1.9 & JSON for fun

2011-02-07 19:16:58

Ever since I found out about the new hash syntax you can use in ruby 1.9, and how similar that syntax is to JSON, I've been waiting for someone to realise you can just abuse eval() for parsing (some) JSON now. --More--

+[NSObject load] in MacRuby

2010-06-12 02:11:32

If you've not heard of it, MacRuby is an implementation of Ruby 1.9 directly on top of Mac OS X core technologies such as the Objective-C runtime and garbage collector, the LLVM compiler infrastructure and the Foundation and ICU frameworks. Basically means you write in Ruby using Objective-C frameworks, and vice versa. It's pretty damn cool to be honest! --More--

Migrating Rubygems to Ruby 1.9.x

2009-01-31 20:29:57

So I just installed ruby 1.9.1 through MacPorts and wanted to easily migrate my rubygems across from 1.8 to see which ones would fail to install. --More--