avoid matching of common ruby and javascript code

Hi,
just tried this gem on a big project and many portions of embedded ruby and javascript code got messed up with wrong translations tag.
I tweaked the regexp and now works much better for me, please take a look if can be interesting to include those changes.

This also shut down some rspec deprecations warnings.