I''ve been solving this problem by requiring RedCloth before the
Initializer
loop in config/environment.rb. YMMV but it works for me.
The question I want to add here is that now that [or as soon as] require_gem
has been officially deprecated, what''s the right way to require a
specific
version of a gem using a regular require? RTFM, right? Hehehe. I know.
I''ve
been "looking" but haven''t run across the way yet. Excuse me
if it''s
obvious.
RSL
On 1/4/07, Johannes Held <hehejo-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:>
>
> Hello,
>
> I have a question about how to include a special version of a gem.
>
> On my server there are two versions of RedCloth: 3.0.3 and 3.0.4.
>
> And I need to use 3.0.3.
>
> If I write a script, I can simply write it like this:
> require ''rubygems''
> require_gem ''RedCloth'', ''3.0.3''
>
> But if I put "require_gem ''RedCloth'',
''3.0.3'' " as first line into
> environment.rb, I get this error:
> /usr/lib/ruby/site_ruby/1.8/rubygems.rb:196:in `activate'':
can''t
> activate RedCloth (= 3.0.3), already activated RedCloth-3.0.4]
> (Gem::Exception)
>
> Can you please tell me, where I can define the versions Rails should
> use?
>
> Johannes Held
>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---