zverok / worldize

Simple coloured countries drawing
260 stars 11 forks source link

gem not working in ubuntu #5

Closed xekhz closed 8 years ago

xekhz commented 8 years ago

hello im trying to build a map using your worldize, that seems to be very good, but it is not working in ubuntu I have the following Operating System Description: Ubuntu 14.04.3 LTS Release: 14.04 Codename: trusty RUBY ruby 1.9.3p484 (2013-11-22 revision 43786) [i686-linux]

CODE SNIPPET: require 'worldize' worldize = Worldize::Countries.new img = worldize.draw # Magick::Image of RMagick img.write('/tmp/blank.png')

I GET THE FOLLOWING ERRORS: /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:60:in require': /var/lib/gems/1.9.1/gems/worldize-0.0.1/lib/worldize.rb:73: syntax error, unexpected tPOW (SyntaxError) def draw_highlighted(*countries, **options) ^ /var/lib/gems/1.9.1/gems/worldize-0.0.1/lib/worldize.rb:79: syntax error, unexpected tPOW ... to_color, value_by_country, **options) ... ^ /var/lib/gems/1.9.1/gems/worldize-0.0.1/lib/worldize.rb:121: syntax error, unexpected keyword_end, expecting $end from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:60:inrescue in require' from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:35:in require' from log_analyzer.rb:109:in

'

How can i use worldize.. thanks for the help

zverok commented 8 years ago

It should be described in README, but Worldize works only on moder Rubies. Modern is > 2.0, where refinements work and hash argument work.

JFYI, support for Ruby 1.9.3 have been ended already, as well as for Ruby 2.0.

I will never have my target in supporting discontinued versions of Ruby.

xekhz commented 8 years ago

thanks for the quick reply... will try modern rubies.