I just created a new gem (using bundler) and want to add Active Record support. So I added s.add_dependency "activerecord", "~> 3.0"
to my gemspec. Then I use Bundler.setup and Bundler.require and thought that I have access to Active Record now, but I haven't. I have to explicitly use require "active_record"
. Any idea why Bunder.require does not work for me in that case?
views:
14answers:
1
+1
A:
If you want use Bundler you need define your Gemfile with Activerecord
gem 'activerecord', "~> 3.0.0"
Or you need define bundler to use your gemspec with adding gemspec in your Gemfile
gemspec
shingara
2010-10-25 17:00:02
There is already gemspec in my Gemfile (bundler does that automatically for newly created gems), so that is not the problem.
Zardoz
2010-10-25 17:14:13