Hi all,
I'm trying to create a gem, I have this directory structure:
mygem
-lib
>-mygem.rb
>-mygem
>-file1.rb
>-file2.rb
In mygem.rb I want to require file1.rb and file2.rb, if I try simply
with
require 'file1.rb'
it doesn't work, so I added
$:.unshift File.join(File.dirname(__FILE__), 'mygem')
so in $: I have mygem/lib/mygem/ directory but the require doesn't work
and I'm getting
LoadError: no such file to load -- file1.rb
I'm trying to work it on ruby 1.8.7
Any idea?
Thanks a lot!
···
--
Posted via http://www.ruby-forum.com/\.