From: Yossef Mendelssohn Date: 2007-07-02T22:27:08+09:00 Subject: Re: Creating a DSL in ruby If I may, you could look into a fluent interface (http:// www.martinfowler.com/bliki/FluentInterface.html) instead of a DSL. I make this distinction because "DSL" seems to have become a term meaning "something with lots of class methods and blocks" because that's one simple Ruby implementation. Michael Hollins suggested something like charge 10.dollars do on "10 July 2007" repeat 12 do charge 20.dollars every :month starting "30 July 2007" end end but how about something like charge(10.dollars).on(date_x).then.charge(20.dollars).every(:month).times(12).starting(date2) instead? If that's not enough to turn you on, look at how well it works with mocking/stubbing in places like RSpec and Mocha (http:// mocha.rubyforge.org/examples/mocha.html). -- -yossef