gettext - Grep for .PO file, or RegEx for a block of text between delimiters -
Start
"single string" Use the GrepRegEx to replace all the msgstr
lines like this: "a string" msgstr "string" "" A long string "" Wrap on several lines. "Msgstr" "" {A long string rolls over multiple lines.} "
In my infinite naivety, I
Msgstr "% 1" msgstr ""% 1 "msgstr" "% 1" msgstr "{\ 1}"
but I can not find it anywhere. After searching the web and after optimizing various solutions for Java or C #, I left and decided to ask here. / P>
For PO translation files if you are looking above, then file syntax.
I am using a text editor for this, TextWangler on Mac OS, which supports GRP Regx syntax.
Thank you.
There are two different patterns "A string" indicates that the following data has the following line code: Because they have two different patterns, and you will be trying to match them all in a regaze yourself. (Unless you use anything other than RegEx with Pearl or some program logic ...) You said that you want to use Text Wrangler, so I will restrict my comments to the limit. I think you will need to find / replace cycles with two rank patterns which can be easily performed in Wrangler (TW). In TW you can use the then a line pattern is < Code> "([^" *] ". The second pattern of `` `` `` This indicates that the data is in multiple rows. / P>
pattern. The second pattern can be matched in BB editing or TW. Msgstr" "" (? Sm)
flag at the beginning of your code . *
At the end of the pattern matching line, TW past Grep saves matches, so once you get your two / pattern that work is easy to find
You can write a Reggae with a variation in order to potentially match in two types and can be nominated once converted. But it will take much less time to write some Perl quickly ...
Comments
Post a Comment