Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Re: Mulitple values for a key in a hash

by tcf03 (Deacon)
on Nov 29, 2007 at 14:50 UTC ( [id://653858] : note . print w/replies, xml ) Need Help??

in reply to Mulitple values for a key in a hash

my %filesystems = ( hosta => { desc => 'x', filesystem => [ qq|/a/b/c +/d/e/f| ] }, hostb => ( desc => 'r', filesystem => [ qq/w/e/r / +home ] } );
Thats how I would write the structure. Although, just a suggestion, I would use an ini file or some sort of config file to hold the host info and build %filesystems with code.

Ive used Config::INI::Reader for such things ( ini files ) and it works well.

"That which we persist in doing becomes easier, not that the task itself has become easier, but that our ability to perform it has improved."
  --Ralph Waldo Emerson