Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reloader should not reload all .rb files in the project #45

Closed
mcmire opened this issue Feb 23, 2010 · 5 comments
Closed

Reloader should not reload all .rb files in the project #45

mcmire opened this issue Feb 23, 2010 · 5 comments

Comments

@mcmire
Copy link
Contributor

mcmire commented Feb 23, 2010

I have tests for my app in test/. If I update a test file and then refresh the app in my browser, it seems that the test file is getting included in Padrino's auto-reloader, which of course causes the app to choke and sputter because the test files weren't meant to be loaded that way. In padrino-core/reloader.rb, is Padrino::Reloader::Stat#rotation loading every .rb file in my project? If so, it would probably be a good idea to exclude test/ or spec/ -- or even better, just reload files in the project root, app/ and lib/ (and possibly config/ too).

@nesquena
Copy link
Member

Yes this is a good point!

@DAddYE
Copy link
Member

DAddYE commented Feb 23, 2010

Yep thanks for this Issue I forgot test/spec !!

@DAddYE
Copy link
Member

DAddYE commented Feb 23, 2010

Hi! Thanks for this issue solved in: http://github.com/padrino/padrino-framework/commit/5ee4781cbded7caf64f69019af29da2411c379c9

Excluded from reloading these dirs: test, tmp, features, spec, config, lib and public.
You can excluder other using Padrino::Reloader.exclude << Padrino.root("myfolder")

Tell me if you have other problems.

Best regards
/DAddYE

@mcmire
Copy link
Contributor Author

mcmire commented Feb 23, 2010

Awesome, thanks for the quick response. I'll give it a try.

@DAddYE
Copy link
Member

DAddYE commented Feb 23, 2010

Try also new admin and tell us your feedback

ujifgc added a commit that referenced this issue Oct 16, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants