Created
January 4, 2013 22:56
-
-
Save dropmeaword/4458263 to your computer and use it in GitHub Desktop.
Explanation of how to write a script that will replace all of goteo's call to Text::get with the adecuate Text::_ call.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
regex: (Text::get) -> replace with: _ | |
regex: (?<=Text::get\(\')(.*)(?=\'\);) returns as match the contents of the id string used as a param, then you look it up in the db and replace it with the actual value. -> lu = lookup(match[0]) /s/match[0]/lu |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment