Change model name in rails

I will need to change one of my model names. Is there anything that replaces each instance of the original model name in controller views and tests, or should I do it all manually, page by page?

+2


a source to share


3 answers


Check out RubyMine from JetBrains, they have good refactoring tools for ruby.



+3


a source


You need to do everything manually, page by page. If you have tests, they should give you clear indications of where it is still being used.



+2


a source


Netbeans has this feature where you can give it the name you want to change throughout your project and it will replace it with your entire codebase.
Get Netbeans 6.9 beta, ruby ​​version http://download.netbeans.org/netbeans/6.9/beta/ , you just select the model name, right click and choose refactoring ... it allows you to even pre-edit before running the refactoring.

+2


a source







All Articles