That's pretty cool
Looks YAML is the way forward there
Cheers
Kingsley
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jeff Wood
Sent: 30 August 2005 00:10
To: wtr-general@rubyforge.org
Subject: Re: [Wtr-general] Key / value pairs.
That's one way
I think this question answered before. You can search archives. But I
added this to wiki FAQ. I also give wiki text here.
Q. What I'd like to do, is to have a configuration file (eg.
config.txt), which would have a number of key/value pairs, such as
UserName=user, which would be read by a test
That's one way to do it ... Another is to use YAML which has a pretty
heavy following with the Ruby community in general...
So, the following would do the same ...
You can simply use a hash to store things... Here's a quick script to
load up a sample
--SCRIPT--
require 'yaml'
config =