Manage radiant gems

Hello,

I would like to package my radiant app before deployment.
I created a gems/ folder under vendor/, and copy the gems which are in
the radiant vendor/ folder and others for my project.
Then, I added the following lines to environment.rb to load my new path
:

config.load_paths += Dir["#{RAILS_ROOT}/vendor/gems/**"].map do |dir|
File.directory?(lib = “#{dir}/lib”) ? lib : dir
end

But it doesn’t work, the radiant gems like ‘rubypants’ can’t be
loading… what is the best way to do that? Can you explain me?

Thank you !
Vincent

Vincent Pérès wrote:

end

But it doesn’t work, the radiant gems like ‘rubypants’ can’t be
loading… what is the best way to do that? Can you explain me?

I’m not sure about this, but I think you’re supposed to freeze the
Radiant gem. It will take care of everything and put it under the
correct paths (I think vendor/radiant)

rake radiant:freeze:gems

Also, you can see if this helps:

Step 5 of: http://kb.mediatemple.net/questions/152/Installing+Radiant

Copy the radiant gem into your application, which will effectively
freeze the version of radiant you are using.
| cp -a ~/data/rubygems/gems/gems/radiant-0.6.6 vendor/radiant|

Cheers,
Mohit.
8/19/2008 | 4:18 PM.

Mohit S. wrote:

Vincent Pérès wrote:

end

But it doesn’t work, the radiant gems like ‘rubypants’ can’t be
loading… what is the best way to do that? Can you explain me?

I’m not sure about this, but I think you’re supposed to freeze the
Radiant gem. It will take care of everything and put it under the
correct paths (I think vendor/radiant)

rake radiant:freeze:gems

Also, you can see if this helps:

Step 5 of: http://kb.mediatemple.net/questions/152/Installing+Radiant

Copy the radiant gem into your application, which will effectively
freeze the version of radiant you are using.
| cp -a ~/data/rubygems/gems/gems/radiant-0.6.6 vendor/radiant|

Cheers,
Mohit.
8/19/2008 | 4:18 PM.

Hello,

Thanks for your quick answer, but I’m ‘unpacking’ the radiant gem to use
it as a project.
‘rake radiant:freeze:gems’ don’t do anything in my project.
In fact I would like to move the radiant gems dependencies in vendor/ to
vendor/gems/ and add my own gems.
Is there a way to do that or is it impossible?

Thanks a lot !
Vincent

You can follow Radiant’s lead and just expand them directly into vendor,
rather than vendor/gems. Radiant automatically adds those to the load
path.

Sean

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs