Craig White wrote:
>>
>> end
>>
>> got my config/preinitializer.rb file
>>
>> Any ideas?
> ----
> It doesn't stick out in my mind so I have to believe that somewhere in
> their documentation, you just add to config/environment.rb (inside the
> initializer loop)
>
> config.gem "geokit"
>
> Craig
>
yeah, I tried that, and it didn't work. (see method #2). I've already
done a google search for that error, and a couple blogs come up that
show methods for fixing it. I've tried their methods, but it hasn't
worked for me.
Craig White wrote:
>>
>> end
>>
>> got my config/preinitializer.rb file
>>
>> Any ideas?
> ----
> It doesn't stick out in my mind so I have to believe that somewhere in
> their documentation, you just add to config/environment.rb (inside the
> initializer loop)
>
> config.gem "geokit"
>
yeah, I tried that, and it didn't work. (see method #2). I've already
done a google search for that error, and a couple blogs come up that
show methods for fixing it. I've tried their methods, but it hasn't
worked for me.
> their documentation, you just add to config/environment.rb (inside the
> initializer loop)
>
> config.gem "geokit"
>
> Craig
>
yeah, I tried that, and it didn't work. (see method #2). I've already
done a google search for that error, and a couple blogs come up that
show methods for fixing it. I've tried their methods, but it hasn't
worked for me.
----
umm... of course it works - I have a fully functional web site working
using exactly that setup. That also is the way to tell rails to use an
installed gem in the application.
Craig
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
yeah, I got all the other gems working fine. (rails, mysql, paperclip,
will_paginate, clearance). Just for some reason, I can't get this one to
work. Actually, I take that back. If I hop into console and require
"geokit", then I can use the API directly. The only thing I can't get to
work is acts_as_mappable. It just keeps saying that it's undefined. My
model is Listing, so when I just hop into console and type "Listing" it
throws the error, even if I require 'geokit' first.
Craig White wrote:
>> > their documentation, you just add to config/environment.rb (inside the
>> > initializer loop)
>> >
>> > config.gem "geokit"
>> >
>> > Craig
>> >
>> yeah, I tried that, and it didn't work. (see method #2). I've already
>> done a google search for that error, and a couple blogs come up that
>> show methods for fixing it. I've tried their methods, but it hasn't
>> worked for me.
> ----
> umm... of course it works - I have a fully functional web site working
> using exactly that setup. That also is the way to tell rails to use an
> installed gem in the application.
>
> Craig
>
>
> --
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
yeah, I got all the other gems working fine. (rails, mysql, paperclip,
will_paginate, clearance). Just for some reason, I can't get this one to
work. Actually, I take that back. If I hop into console and require
"geokit", then I can use the API directly. The only thing I can't get to
work is acts_as_mappable. It just keeps saying that it's undefined. My
model is Listing, so when I just hop into console and type "Listing" it
throws the error, even if I require 'geokit' first.
>> done a google search for that error, and a couple blogs come up that
> --
model is Listing, so when I just hop into console and type "Listing" it
throws the error, even if I require 'geokit' first.
----
I don't use the plugin, don't use any 'require' anything just...
config/environment.rb
config.gem "geokit"
'
and in my model...
acts_as_mappable
that's it - nothing more... restart the web server, open a console -
done.
Craig
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
hmm, yeah. It's the weirdest thing. I started a fresh app and tried just
that, and it was a no go. I still get undefined method
acts_as_mappable.... I'm not sure what's going on, but that's for the
help
hmm, yeah. It's the weirdest thing. I started a fresh app and tried just
that, and it was a no go. I still get undefined method
acts_as_mappable.... I'm not sure what's going on, but that's for the
help
Did you ever get anywhere on this issue? Were you using Bundler at the
time? I just ran into it while setting up an existing application to use
Bundler. Upon disabling Bundler, everything works as before, so I'm
certain it's a Bundler bug... Not sure where to start on it.
hmm, yeah. It's the weirdest thing. I started a fresh app and tried just
that, and it was a no go. I still get undefined method
acts_as_mappable.... I'm not sure what's going on, but that's for the
help
Did you ever get anywhere on this issue? Were you using Bundler at the
time? I just ran into it while setting up an existing application to use
Bundler. Upon disabling Bundler, everything works as before, so I'm
certain it's a Bundler bug... Not sure where to start on it.
Solved it! First, make sure you don't have the geokit-rails plugin
installed. It just confuses Bundler and Rails. Then make sure you
specify in your Gemfile BOTH the geokit gem AND the geokit-rails gem,
something like this:
If you're on Rails 3, that should do it. If you're on Rails 2 like me,
you'll need to make sure you follow the instructions on the Bundler
website: Gem Bundler – Manage your Ruby gems