in reply to Re: Mulitple values for a key in a hash
in thread Mulitple values for a key in a hash
$filesystem = $ARGV[0]; #store the file system you would like to run D +U command on if ( $ARGV[0] eq "" ) { die "usage: $0 filename\n"; } $host=`hostname`; my %filesystems = ( hosta => { desc => 'x', filesystemA => [ q +q|/the/first/filesystem|], filesystemB => [ qq|/the/second/fielsyste +m| ] }, hostb => { desc => 'r', filesystemA => [ q +q|/the/first/filesystem | ], filesystemB => [qq|no filesystemB for 2n +d host |]} ); $choice = $filesystems{$host}; if ( not $filesystems{filesystemA}{$filesystem} ) { print "error\n"; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Mulitple values for a key in a hash (Pennance Required)
by roboticus (Chancellor) on Nov 29, 2007 at 17:03 UTC | |
by wishartz (Beadle) on Nov 30, 2007 at 11:29 UTC | |
by roboticus (Chancellor) on Nov 30, 2007 at 20:48 UTC | |
by wishartz (Beadle) on Dec 03, 2007 at 11:42 UTC | |
Re^3: Mulitple values for a key in a hash
by sh1tn (Priest) on Nov 29, 2007 at 18:49 UTC | |
by wishartz (Beadle) on Nov 30, 2007 at 13:54 UTC | |
by wishartz (Beadle) on Dec 03, 2007 at 09:42 UTC |