I'm going to need to change one of my model names. Is there anything out there that will replace every instance of the original model name in the controllers views and tests or do I have to do it all manually, page by page?
A:
You have to do all manually, page by page. If you have tests, they should give you clear indications of where it is still in use.
Ryan Bigg
2010-05-06 22:21:30
hrm... thought so. This will be fun.
Kenji Crosland
2010-05-06 22:29:39
you don't have to do it by hand, the Netbeans IDE can help you handle this, see my answer below.
concept47
2010-05-07 02:32:52
You don't have to do it manually either if you use RubyMine.
jpartogi
2010-05-07 03:52:56
I'll give them a try. Thanks.
Kenji Crosland
2010-05-08 00:32:53
+3
A:
Check out RubyMine from JetBrains, they have some good refactoring tools for ruby.
Aymeric
2010-05-06 23:50:19
+2
A:
Netbeans has this feature, where you can give it a Name you want to change in your entire project and it'll replace it through your entire code base.
Get Netbeans 6.9 beta, the ruby version http://download.netbeans.org/netbeans/6.9/beta/, you just select the model name, right click and pick refactor ... it allows you even preview changes before you run the refactor.
concept47
2010-05-07 02:32:14