Did you write a regular expression to do the migration?
@Jankeesvw Nope, did it the manual way. For each controller I grepped through the codebase and manually made the edits. With some vim find-and-replace magic of course. But more manual than I would have liked.
I did consider automating it in some way, but we have a bunch of different ways in our HAML views (and elsewhere) to define our targets so I couldn’t come up with a good approach.
There’s also some optional, but recommended functional changes you can make. Such as using value change callbacks to do some of your heavy lifting. I did those in the same go. Next time I’d probably break it up into smaller, shippable iterations.
I also upgraded my project, did 90% with a regular expression. But I only updated to the new target syntax.
@Jankeesvw Oh nice. Mind sharing that regex? Maybe worthy of a quick blog post.
@marc this is what I used, you still need some changes. But it gets you quite far.
A blog post sounds good, but this regular expression is not perfect some cases are not well replaced. So I'm not that happy with it.