U
Une Bévue
i wanted to test wxRuby with the simplest script :
------------------------------------------------------------------------
#! /usr/bin/env ruby
# If you installed the wxruby gem, uncomment the following two lines:
require 'rubygems'
#gem 'wxruby-1.9.3-universal-darwin' #'wxruby2-preview'
# or the name of the gem you installed
#gem 'wxruby-1.9.3' #'wxruby2-preview'
gem 'wxruby'
require "wxruby" # wxruby 0.6.0
# OR
require "wx" # wxruby2
include Wx
class MinimalApp < App
def on_init
Frame.new(nil, -1, "The Bare Minimum").show()
end
end
------------------------------------------------------------------------
I've installed "wxruby-1.9.3-universal-darwin"
for the "gem" line if i use :
gem 'wxruby-1.9.3-universal-darwin' or
gem 'wxruby-1.9.3' i get an error :
/opt/local/lib/ruby/site_ruby/1.8/rubygems.rb:499:in
`report_activate_error': Could not find RubyGem wxruby-1.9.3 (>= 0)
(Gem::LoadError)
from /opt/local/lib/ruby/site_ruby/1.8/rubygems.rb:131:in
`activate'
from /opt/local/lib/ruby/site_ruby/1.8/rubygems.rb:49:in `gem'
from ./essai.rb:6
and, if i comment this line, i get an error with the following (require
"wxruby") :
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in
`gem_original_require': no such file to load -- wxruby (LoadError)
from
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in
`require'
from ./essai.rb:8
obviously i've verified wxruby is installed :
$ gem list --local w
*** LOCAL GEMS ***
wx_sugar (0.1.20)
wxruby (1.9.3)
the installation of wxruby and wx_sugar have been done thru gem.
i didn't install anything (no dependencies)
MinimalApp.new.main_loop
------------------------------------------------------------------------
#! /usr/bin/env ruby
# If you installed the wxruby gem, uncomment the following two lines:
require 'rubygems'
#gem 'wxruby-1.9.3-universal-darwin' #'wxruby2-preview'
# or the name of the gem you installed
#gem 'wxruby-1.9.3' #'wxruby2-preview'
gem 'wxruby'
require "wxruby" # wxruby 0.6.0
# OR
require "wx" # wxruby2
include Wx
class MinimalApp < App
def on_init
Frame.new(nil, -1, "The Bare Minimum").show()
end
end
------------------------------------------------------------------------
I've installed "wxruby-1.9.3-universal-darwin"
for the "gem" line if i use :
gem 'wxruby-1.9.3-universal-darwin' or
gem 'wxruby-1.9.3' i get an error :
/opt/local/lib/ruby/site_ruby/1.8/rubygems.rb:499:in
`report_activate_error': Could not find RubyGem wxruby-1.9.3 (>= 0)
(Gem::LoadError)
from /opt/local/lib/ruby/site_ruby/1.8/rubygems.rb:131:in
`activate'
from /opt/local/lib/ruby/site_ruby/1.8/rubygems.rb:49:in `gem'
from ./essai.rb:6
and, if i comment this line, i get an error with the following (require
"wxruby") :
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in
`gem_original_require': no such file to load -- wxruby (LoadError)
from
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in
`require'
from ./essai.rb:8
obviously i've verified wxruby is installed :
$ gem list --local w
*** LOCAL GEMS ***
wx_sugar (0.1.20)
wxruby (1.9.3)
the installation of wxruby and wx_sugar have been done thru gem.
i didn't install anything (no dependencies)
MinimalApp.new.main_loop