Possible Duplicate:
Pass variables to ruby script via command line
I am trying to pass the HOSTNAME as a parameter into a ruby script. Is this possible? This is what I believe should work, but it doesn't.
%h% = HOSTNAME
ECHO %h%
ruby this.rb %h%
pause
And the ruby code is
val = ARGV[0]
puts "Value is #{val}"