Hi Working through the tut material in teh PP book (agile dev with rails) on a laptop running winxp. Creating the "admin" application, things generally work great. Except: at teh end of chapter 6, when we update teh css to improve the look of the page - I copy the new scaffold.css into my working directory, but webrick keeps serving the old css, even after a restart. Very odd. The file at c:/rails/depot/public/stylesheets/scaffold.css is definitely different from what I get when I navigate to http://127.0.0.1:3000/stylesheets/scaffold.css (teh webrick was started in c:/rails/depot). anyone have any idea why? (i bet it would be fine on my linux box at home ;-)) thanks! Daniel -- Posted via http://www.ruby-forum.com/.
Daniel, A few things that come to mind .. - Have you checked in the html source (the page that''s in your browser) that the META tag actually points to this one? - Browser caching? (I''ve config''d my browsers with cache disabled so that''s never the issue, because I''ve seen problems with this in the past) - A typo (i know that''s never possible .. ;-) in: app/views/layouts/*.rhtml Regards, Gerard. On Friday 23 December 2005 12:14, Daniel McBrearty tried to type something like:> Hi > > Working through the tut material in teh PP book (agile dev with rails) > on a laptop running winxp. > > Creating the "admin" application, things generally work great. Except: > at teh end of chapter 6, when we update teh css to improve the look of > the page - I copy the new scaffold.css into my working directory, but > webrick keeps serving the old css, even after a restart. Very odd. The > file at > > c:/rails/depot/public/stylesheets/scaffold.css > > is definitely different from what I get when I navigate to > > http://127.0.0.1:3000/stylesheets/scaffold.css > > (teh webrick was started in c:/rails/depot). > > anyone have any idea why? (i bet it would be fine on my linux box at > home ;-)) > > thanks! > > Daniel-- "Who cares if it doesn''t do anything? It was made with our new Triple-Iso-Bifurcated-Krypton-Gate-MOS process ..." My $Grtz =~ Gerard; ~ :wq!
Daniel McBrearty
2005-Dec-23 12:55 UTC
Re: webrick / winxp won''t stop serving cached file??
thanks Gerard, I tried a few of those things - closed and restarted teh browser, checked the path ... the problem didn''t go away until I renamed scaffold.css, requested it again (got an error) and then named it back. So maybe teh caching is more obstinate than I realised (cached across browser instances?) cheers! daniel -- Posted via http://www.ruby-forum.com/.
Has anyone seen any docs on how to maintain multiple environments on the same machine? Specifically, I''m wondering how I can maintain a "dev" and a "qa" environment on the same machine. I want to be able to have "qa" match the production environment in terms of which gems and with versions of the gems it has while upgrading the gems in the dev environment on a different schedule. That way I could, for example, keep dev up to date with the latest rails gems while not upgrading the qa environment until I''m testing for a release. Using Java this is pretty easy in terms of environments - you simply set a "JAVA_HOME" which defines the jdk you''re using and then you include whichever versions of the jar files you need in the classpath for each environment. What''s the Ruby/Rails/Gems equivalent process?
Daniel, Had that before as well, while removing it and putting it back only then the browser seems to really refresh. Like I said, I''ve seen browsers cache even when doing an unconditional refresh. So when developing I always disable cache, because that completely eliminates the formentioned problem. Regards, Gerard. On Friday 23 December 2005 13:55, Daniel McBrearty tried to type something like:> thanks Gerard, > > I tried a few of those things - closed and restarted teh browser, > checked the path ... the problem didn''t go away until I renamed > scaffold.css, requested it again (got an error) and then named it back. > So maybe teh caching is more obstinate than I realised (cached across > browser instances?) > > cheers! > > daniel-- "Who cares if it doesn''t do anything? It was made with our new Triple-Iso-Bifurcated-Krypton-Gate-MOS process ..." My $Grtz =~ Gerard; ~ :wq!
rake freeze_gems will import the current version of rails + gems into the vendor directory of a rails app. It''s also possible to use gem to unpack specific versions there. http://weblog.textdrive.com/article/180/depending-on-your-vendor- directory cheers, David On 24/12/2005, at 12:38 AM, Kevin Bedell wrote:> Has anyone seen any docs on how to maintain multiple environments > on the same > machine? Specifically, I''m wondering how I can maintain a "dev" and > a "qa" > environment on the same machine. > > I want to be able to have "qa" match the production environment in > terms of > which gems and with versions of the gems it has while upgrading the > gems in the > dev environment on a different schedule. That way I could, for > example, keep dev > up to date with the latest rails gems while not upgrading the qa > environment > until I''m testing for a release. > > Using Java this is pretty easy in terms of environments - you > simply set a > "JAVA_HOME" which defines the jdk you''re using and then you include > whichever > versions of the jar files you need in the classpath for each > environment. > > What''s the Ruby/Rails/Gems equivalent process? > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails
On Fri, 2005-12-23 at 08:38 -0500, Kevin Bedell wrote:> Has anyone seen any docs on how to maintain multiple environments on the same > machine? Specifically, I''m wondering how I can maintain a "dev" and a "qa" > environment on the same machine. > > I want to be able to have "qa" match the production environment in terms of > which gems and with versions of the gems it has while upgrading the > gems in the > dev environment on a different schedule. That way I could, for example, > keep dev > up to date with the latest rails gems while not upgrading the qa environment > until I''m testing for a release. > > Using Java this is pretty easy in terms of environments - you simply set a > "JAVA_HOME" which defines the jdk you''re using and then you include whichever > versions of the jar files you need in the classpath for each environment.http://docs.rubygems.org/read/chapter/3#page13 GEM_HOME looks like it can tell ruby to use a specific location for gems. You could set it separately for each "environment" in the webserver''s exported variables. But you''d need to maintain several gem repositories. Or make use of freeze_gems and such as David suggested. -Matthew Beale mixonic-8rZIAEcCR/xWk0Htik3J/w@public.gmane.org :: 607 227 0871 Resume and Portfolio @ http://madhatted.com
Daniel McBrearty
2005-Dec-23 14:48 UTC
Re: Re: webrick / winxp won''t stop serving cached file??
Hi Gerard Have you any idea how to do that in firefox? I only see options to clear the cache and set its size in "options". thanks! Daniel -- Posted via http://www.ruby-forum.com/.
Gerard
2005-Dec-23 15:34 UTC
Re: Re: Re: webrick / winxp won''t stop serving cached file??
Daniel, Set the size to 0 KB. Regards, Gerard. Set theOn Friday 23 December 2005 15:48, Daniel McBrearty tried to type something like:> Hi Gerard > > Have you any idea how to do that in firefox? I only see options to clear > the cache and set its size in "options". > > thanks! > > Daniel-- "Who cares if it doesn''t do anything? It was made with our new Triple-Iso-Bifurcated-Krypton-Gate-MOS process ..." My $Grtz =~ Gerard; ~ :wq!