require_gem question

A

Andrew Gibson

Does require_gem also load all of the listed dependencies in the gem
spec or are those dependencies loaded by manually through require
statements?

so example:
require_gem 'rails'

the rails gem has:
actionwebservice
actionmailer
actionpack
activerecord
activesupport
rake
as listed dependencies.

so does require_gem 'rails' also perform require_gem 'actionamailer',
etc... ? or is there a specific 'require' statement somewhere in 'rails'
?
 
E

Eric Hodel

Does require_gem also load all of the listed dependencies in the gem
spec or are those dependencies loaded by manually through require
statements?

so example:
require_gem 'rails'

the rails gem has:
actionwebservice
actionmailer
actionpack
activerecord
activesupport
rake

require_gem is only useful for picking a particular version of a
gem. If you don't manually specify the version of the dependent gems
(in dependency order) you'll get whatever their gemspecs need.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top