Created
March 20, 2014 18:36
-
-
Save rdark/9670800 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# | |
mock_dist = { | |
:arch => "i386", | |
:distribution => "epel", | |
:release => "6", | |
} | |
mock_arch = mock_dist[:arch] | |
mock_dist = mock_dist[:distribution] | |
mock_rel = mock_dist[:release] | |
[mock_arch, mock_dist, mock_rel].each do |m| | |
puts "#{m}" | |
end | |
$ ./tmp/test.rb | |
./tmp/test.rb:11:in `[]': no implicit conversion of Symbol into Integer (TypeError) | |
from ./tmp/test.rb:11:in `<main>' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment