Forum: Ruby on Rails lib directory cached?

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Jim J. (Guest)
on 2006-04-28 09:18
I am testing my app on a shared host account on Site5.

The app is in development mode and all changes for the most part take
place immediately.  The only exception are the classes that I have
developed and placed in my lib/ directory.

I can make a change to my class, run my app, have it behave in the
previous manner, go to bed, come back the next morning, and the changes
will have taken effect.

How do I prevent the server (Apache in this case) from caching my lib/
directory?

TIA.
Dan S. (Guest)
on 2006-04-28 10:19
(Received via mailing list)
Hi Jim

> How do I prevent the server (Apache in this case) from caching my lib/
> directory?

I've faced the same problem too, apparently using "requre_dependency
'my_lib'" can fix this if you put that in the controller/model that
it's used from. It's supposed to force a reload each time the file is
reloaded and parsed.

That being said, I've never used it, so i might be talking crap.

It might be a bit nicer on the Site5 mob if you do your dev work on
your local machine and deploy it only when you're ready to roll,
though.

Have a shot, hope it helps.

Dan.
This topic is locked and can not be replied to.